You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Agent Host:浏览器重连/会话恢复后工具从 No client connected 变为 does not exist,旧共享页失效 #340718
VS Code 的 Copilot SDK / Agent Host 会话在浏览器客户端重连及会话恢复期间,浏览器工具先返回 No client connected,之后调用同一个工具返回 Tool 'openBrowserPage' does not exist.。再次恢复会话后工具可执行,但原共享页面失效;强制新建空白页面并读取成功。
Agent Host: After browser reconnect / session restore, tool changes from "No client connected" to "does not exist"; old shared page becomes invalid
Body:
Problem Overview
During browser client reconnection and session restoration of a VS Code Copilot SDK / Agent Host session, the browser tool first returns No client connected, and then calling the same tool returns Tool 'openBrowserPage' does not exist.. After restoring the session again, the tool can execute, but the original shared page becomes invalid; forcibly creating a new blank page and reading it succeeds.
I would like a review of browser client tool registration, tool refresh on reconnect, and the recovery and error messaging for invalidated shared pages. The current evidence is insufficient to determine the root cause, and it cannot prove that a particular model does not support browser tools.
Model: claude-sonnet-5 at the time of the first failure; subsequently auto-routed and recorded as gpt-6.1-sol
Actual Steps and Results
Times are 2026-10-09 UTC+08:00. The following is a redacted summary extracted from the local session log; raw logs are not attached.
Time
Operation
Actual Result
17:08
openBrowserPage requests to share an existing page
Returned a result indicating the user had not shared a page, showing the tool could execute at that time
20:41
openBrowserPage; on an existing page readPage → navigatePage(type=reload) → readPage
All returned No client connected
20:42–20:43
User reported being connected; after restoring the same-model session, called openBrowserPage again
Returned Tool 'openBrowserPage' does not exist.
From 20:45
Session restored and auto-routed to another model; read existing page → refresh → re-read
All returned Page "<original shared page ID>" not found
Then
openBrowserPage({"url":""})
Returned the same error that the original shared page does not exist
Then
`openBrowserPage({"url":"(redacted)
Succeeded, returned a new page ID
Then
readPage reading the new page
Succeeded, URL was `(redacted)
Then
openBrowserPage({})
Returned a result indicating the user had not shared an existing page — no longer "tool does not exist" or "client not connected"
The above sequence is the observed failure path; it has not been repeatedly reproduced in a clean session. Model switching and client recovery happened simultaneously, so success cannot be attributed to the model switch.
Reproduction Path for Investigation
In an Agent Host / Copilot SDK session that supports the integrated browser tools, share a browser page.
Have the client disconnect and reconnect, and restore the same session.
Call openBrowserPage, then read, refresh, and re-read an existing page.
Check whether the tool changes from No client connected to Tool 'openBrowserPage' does not exist., and whether the page ID becomes invalid.
Compare against creating a new `(redacted) page and reading it.
Expected
After the client reconnects, the existing session's browser tool registration should stay consistent with the currently active client.
If the tool or the old shared page needs to be re-bound, an actionable recovery hint should be returned, rather than making the user repeatedly reconnect, re-share, or switch models.
Distinguish between "no client", "tool not registered", "page ID invalid", and "user has not authorized sharing".
Impact and Verified Temporary Recovery
The workflow was interrupted because the already-logged-in page could not be read. After forcibly creating a new blank page, the open and read tools actually succeeded; the original page's authorization was not restored as a result. No other channel was used to bypass page login or access authorization.
Related Issues
This may be related to the client-reconnection / old-client-ownership phenomenon in #331289, but there are no protocol logs here to prove it is the same root cause; this time there was also a clear "tool does not exist" error.
There are no AHP protocol logs available on this machine, so no inference is made about client ID ownership or the tool registration implementation. No business pages, internal addresses, account information, page IDs, raw logs, or any credentials were uploaded.
This report was submitted at the explicit request of the user, organized with AI assistance, and the local version and actual tool-call results were verified.
Warning
Firewall blocked 1 domain
The following domain was blocked by the firewall during workflow execution:
host.docker.internal
To allow these domains, add them to the network.allowed list in your workflow frontmatter:
Activity
vs-code-engineering commentedon Oct 9, 2026
AI Translation:
Title:
Agent Host: After browser reconnect / session restore, tool changes from "No client connected" to "does not exist"; old shared page becomes invalid
Body:
Problem Overview
During browser client reconnection and session restoration of a VS Code Copilot SDK / Agent Host session, the browser tool first returns
No client connected, and then calling the same tool returnsTool 'openBrowserPage' does not exist.. After restoring the session again, the tool can execute, but the original shared page becomes invalid; forcibly creating a new blank page and reading it succeeds.I would like a review of browser client tool registration, tool refresh on reconnect, and the recovery and error messaging for invalidated shared pages. The current evidence is insufficient to determine the root cause, and it cannot prove that a particular model does not support browser tools.
Environment
Actual Steps and Results
Times are 2026-10-09 UTC+08:00. The following is a redacted summary extracted from the local session log; raw logs are not attached.
openBrowserPagerequests to share an existing pageopenBrowserPage; on an existing pagereadPage→navigatePage(type=reload)→readPageNo client connectedopenBrowserPageagainTool 'openBrowserPage' does not exist.Page "<original shared page ID>" not foundopenBrowserPage({"url":""})readPagereading the new pageopenBrowserPage({})The above sequence is the observed failure path; it has not been repeatedly reproduced in a clean session. Model switching and client recovery happened simultaneously, so success cannot be attributed to the model switch.
Reproduction Path for Investigation
openBrowserPage, then read, refresh, and re-read an existing page.No client connectedtoTool 'openBrowserPage' does not exist., and whether the page ID becomes invalid.Expected
Impact and Verified Temporary Recovery
The workflow was interrupted because the already-logged-in page could not be read. After forcibly creating a new blank page, the open and read tools actually succeeded; the original page's authorization was not restored as a result. No other channel was used to bypass page login or access authorization.
Related Issues
This may be related to the client-reconnection / old-client-ownership phenomenon in #331289, but there are no protocol logs here to prove it is the same root cause; this time there was also a clear "tool does not exist" error.
There are no AHP protocol logs available on this machine, so no inference is made about client ID ownership or the tool registration implementation. No business pages, internal addresses, account information, page IDs, raw logs, or any credentials were uploaded.
This report was submitted at the explicit request of the user, organized with AI assistance, and the local version and actual tool-call results were verified.
Warning
Firewall blocked 1 domain
The following domain was blocked by the firewall during workflow execution:
host.docker.internalTo allow these domains, add them to the
network.allowedlist in your workflow frontmatter:See Network Configuration for more information.
kycutler commentedon Nov 3, 2026
Thanks for reporting! This should be fixed by #340894. Please re-open if you still see the issue.