fix(ui): stop reconnect and polling loops when the host thread is gone
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 新手友好度
- 45/100
- Issue 類型
- 缺陷
- 描述清晰度
- 描述清楚
- 活躍度
- 活躍
- 技術堆疊
- typescript
- 領域
- devtools
研究方向
Start with ReconnectLoop.run in src/ui/reconnect.ts (lines 26-37), where retries currently ignore everything except StopReconnectError. Then check how the host_thread_missing error reaches the logs and stream panels (src/ui/logs-panel.ts around 239-243, src/ui/simulator-panel.ts around 518), and the timers in src/ui/plugin-updates.ts:48 and src/ui/simulator-panel.ts:776. Done means that a missing thread stops every timer and shows "Session closed" in the panel, and that the loop no longer calls the host.
由索引模型根據 Issue 內容生成。
描述
Problem
When the Codex thread behind a panel is gone, UI panels keep calling the host forever. Host calls fail with MCP error -32600: thread not found, and the panel retries roughly every 10 s with no end.
Cause
ReconnectLoop.run(src/ui/reconnect.ts:26-37) retries every error that is not aStopReconnectError, with backoff capped at 10 s.- "thread not found" arrives as a JSON-RPC
McpError, not anisErrorresult, sosrc/ui/logs-panel.ts:239-243never turns it into a stop. - The stream panel starts the same loop at
src/ui/simulator-panel.ts:518. - These other timers also never check for a dead thread:
- the plugin-update interval (
src/ui/plugin-updates.ts:48) - device-apps discovery (
src/ui/simulator-panel.ts:776)
- the plugin-update interval (
Commit 44f1b66 now classifies host_thread_missing as session_closed and stops reporting it, so it disappears from Sentry. The loop still hits the host, and probably adds to the "App server request queue is full" errors.
Evidence (Sentry)
- MOBILE-DEV-UI-14: 64k events from only 3–5 users per release, tagged
operation: mobile_logs_session. About 17k events each on 0.1.147 and 0.1.163, which points to a few panels stuck in a loop. - MOBILE-DEV-UI-W:
mobile_check_plugin_update, 76 users - MOBILE-DEV-UI-V: device-apps discovery, stage
transport - MOBILE-DEV-UI-16, MOBILE-DEV-UI-17, MOBILE-DEV-UI-2J
- Related queue-full issues: MOBILE-DEV-UI-7, MOBILE-DEV-UI-1A
Suggested fix
Treat host_thread_missing as terminal in these places:
ReconnectLoop- the logs and stream receive paths
- device-apps discovery
- the plugin-update interval
Then stop all timers and show "Session closed" in the panel.
- 主要語言
- C++
- 星號
- 243
- 分支
- 21
- 平均合併
- 15 小時 6 分鐘
- 30 天內合併 PR
- 57
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 沒有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
callstackincubator/codex-mobile-dev-plugin 的其他 Issue
-
enhancement
難度 4/5 3-5 天 新手友好度 35/100
callstackincubator/codex-mobile-dev-plugin#119 ·
維護者通常 1 天內回覆
-
documentation
難度 3/5 1-2 天 新手友好度 45/100
callstackincubator/codex-mobile-dev-plugin#117 ·
維護者通常 1 天內回覆
-
enhancement
難度 3/5 1-2 天 新手友好度 45/100
callstackincubator/codex-mobile-dev-plugin#116 ·
維護者通常 1 天內回覆
-
enhancement
難度 3/5 1-2 天 新手友好度 55/100
callstackincubator/codex-mobile-dev-plugin#115 ·
維護者通常 1 天內回覆
-
bug
難度 3/5 1-2 天 新手友好度 45/100
callstackincubator/codex-mobile-dev-plugin#114 ·
維護者通常 1 天內回覆
查看 callstackincubator/codex-mobile-dev-plugin 的全部 Issue
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 72/100
CachyOS/packageinstaller#144 ·
維護者通常 1 天內回覆
-
documentation
難度 1/5 1 小時以內 新手友好度 82/100
TomerAberbach/profiler-md#951 ·
維護者通常 1 天內回覆
-
[Bug] Default key routing (JavaStringHash) picks a different partition than the Java client for about half of keys可能已有人在做 @0z5a 今天認領。 未關閉
難度 2/5 1-3 小時 新手友好度 82/100
apache/pulsar-client-go#1575 ·
維護者通常 2 天內回覆
-
難度 2/5 1-3 小時 新手友好度 72/100
pocoproject/poco#5764 ·
維護者通常 2 天內回覆
-
bug cpp-core-guidelines low-priority
難度 2/5 1-3 小時 新手友好度 62/100
NatronGitHub/openfx-supportext#164 ·
維護者通常 1 天內回覆