Skip to content

Commit 656447f

Browse files
authored
added documentation for invalid session id exception (#1881)
Co-authored-by: Diego Molina <diemol@users.noreply.github.com> [deploy site]
1 parent 7ba611e commit 656447f

File tree

4 files changed

+45
-0
lines changed

4 files changed

+45
-0
lines changed

website_and_docs/content/documentation/webdriver/troubleshooting/errors/_index.en.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,3 +97,15 @@ and have destroyed the context in which the element was located.
9797
You can't just relocate it from the current context,
9898
and you can't switch back to an active context where it is valid. If this is the reason
9999
for your error, you must both navigate back to the correct location and relocate it.
100+
101+
## Invalid SessionId Exception
102+
103+
Sometimes the session you're trying to access is different than what's currently available
104+
105+
### Likely Cause
106+
107+
This usually occurs when the session has been deleted (e.g. `driver.quit()`) or if the session has changed, like when the last tab/browser has closed (e.g. `driver.close()`)
108+
109+
### Possible Solutions
110+
111+
Check your script for instances of `driver.close()` and `driver.quit()`, and any other possible causes of closed tabs/browsers. It could be that you are locating an element before you should/can.

website_and_docs/content/documentation/webdriver/troubleshooting/errors/_index.ja.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,3 +91,15 @@ and have destroyed the context in which the element was located.
9191
You can't just relocate it from the current context,
9292
and you can't switch back to an active context where it is valid. If this is the reason
9393
for your error, you must both navigate back to the correct location and relocate it.
94+
95+
## Invalid SessionId Exception
96+
97+
Sometimes the session you're trying to access is different than what's currently available
98+
99+
### Likely Cause
100+
101+
This usually occurs when the session has been deleted (e.g. `driver.quit()`) or if the session has changed, like when the last tab/browser has closed (e.g. `driver.close()`)
102+
103+
### Possible Solutions
104+
105+
Check your script for instances of `driver.close()` and `driver.quit()`, and any other possible causes of closed tabs/browsers. It could be that you are locating an element before you should/can.

website_and_docs/content/documentation/webdriver/troubleshooting/errors/_index.pt-br.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,3 +91,15 @@ and have destroyed the context in which the element was located.
9191
You can't just relocate it from the current context,
9292
and you can't switch back to an active context where it is valid. If this is the reason
9393
for your error, you must both navigate back to the correct location and relocate it.
94+
95+
## Invalid SessionId Exception
96+
97+
Sometimes the session you're trying to access is different than what's currently available
98+
99+
### Likely Cause
100+
101+
This usually occurs when the session has been deleted (e.g. `driver.quit()`) or if the session has changed, like when the last tab/browser has closed (e.g. `driver.close()`)
102+
103+
### Possible Solutions
104+
105+
Check your script for instances of `driver.close()` and `driver.quit()`, and any other possible causes of closed tabs/browsers. It could be that you are locating an element before you should/can.

website_and_docs/content/documentation/webdriver/troubleshooting/errors/_index.zh-cn.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,3 +98,12 @@ WebDriver并不会自动重新定位,
9898
也无法切换回元素有效的活动上下文。
9999
如果这是您的错误原因,
100100
您必须回到正确的位置并重新定位元素。
101+
102+
## 无效 SessionId 异常
103+
有时您尝试访问的会话与当前可用的会话不同。
104+
105+
### 可能原因
106+
通常发生在会话被删除时(例如:`driver.quit()`)或会话发生更改时,例如最后一个标签页/浏览器已关闭(例如:`driver.close()`)。
107+
108+
### 可能的解决方案
109+
检查脚本中是否有 `driver.close()``driver.quit()` 的实例,以及其他可能导致标签页/浏览器关闭的原因。可能是您在应该/能够定位元素之前就尝试定位了该元素。

0 commit comments

Comments
 (0)