[Bug] 内置浏览器渲染管线静默失效:JS 存活但绘制/截图后端不可用,仅重启应用可恢复
Nobody has claimed this yet.
- Dominant language
- No language data
- Stars
- 22
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
提交前确认 · Pre-submission checklist
- 我已搜索过现有 issue,确认这不是重复 / I searched existing issues and confirmed this isn't a duplicate.
- 我已阅读 CONTRIBUTING.md / I've read CONTRIBUTING.md.
问题类别 · Category
稳定性 / 崩溃 · Stability / Crash
涉及的 Agent 框架 · Agent framework
不涉及框架 · Not framework-specific
严重程度 · Severity
影响体验 · Major (功能可用但体验受损 / works but degraded)
复现频率 · Reproducibility
仅一次 · Once
问题描述 · Description
内置浏览器(IAB)在应用长时间运行后出现渲染层静默失效:页面外壳与 JS 仍正常运行(网络请求成功、DOM 快照可读取、Outlook 文件夹未读计数持续更新),但需要实际绘制的功能全部失败——Outlook 虚拟化邮件列表不渲染(一直停留在加载 splash)、元素点击 actionability 超时、tab.screenshot() 报 "browser screenshot activity capture failed for guest"。故障在回合结束时记录为 browser.turn_screenshot.capture_failed / errorCode=backend_unavailable。标签页级操作(reload、关闭重开、新会话、setViewportSize)均无法恢复,只有重启 ZCode 应用才恢复。
复现步骤 · Steps to reproduce
- 内置浏览器打开 Outlook Web(outlook.live.com/mail),保持应用运行 18+ 小时,定时任务周期性通过 Browser Use 读取页面(reload + domSnapshot)
- 本地时间 9/2 00:01 起,回合结束截图开始报 backend_unavailable(当天首个故障信号,此时 DOM 仍可正常读取)
- 9/2 03:00 起恶化:DOM 外壳仍在(文件夹计数跨小时持续更新),但邮件虚拟列表 listbox 恒为空、getByRole(...).click() 全部 actionability 超时(疑似被加载遮罩拦截)、tab.screenshot() 失败
- 依次尝试恢复均无效:tab.reload() ×4、关闭标签页后新建、新建浏览器会话标签页、setViewportSize 两次强制重排后重新 goto
- 重启 ZCode 应用后同一页面立即完全恢复正常
期望表现 · Expected behavior
渲染/合成层异常时能自动重建 webview 或其绘制后端;至少 reload 或新建标签页应能恢复;截图后端失效不应拖垮依赖可见性计算的虚拟列表渲染与点击 hit-test。
实际表现 · Actual behavior
共享的浏览器渲染组件静默失效后无法通过任何标签页级操作恢复,必须重启整个应用;期间 JS 与网络层一直正常(说明 WebContent/JS 引擎存活,仅绘制管线与 hit-testing 失效)。系统层面无 .ips 崩溃报告、统一日志无 crash/hang/jetsam 记录,即无进程级崩溃记录,疑似 webview 与合成/GPU 进程的连接被静默断开且未重建。
ZCode 版本 · ZCode version
3.10.2 (3.10.2.6414)
设备 / 系统 / 浏览器 · Device / OS / Browser
Mac mini(Apple Silicon, arm64),macOS 26.6.2,ZCode 桌面版内置浏览器
截图 / 录屏 / 日志 · Screenshots / Recordings / Logs
日志文件 ~/.zcode/cli/log/zcode-2026-09-02.jsonl:2026-09-01T16:01Z 至 2026-09-02T09:00Z(本地 UTC+8 为 9/2 00:01–17:00)共 6 条 warn:
event=browser.turn_screenshot.capture_failed
message="Browser turn screenshot capture returned no displayable image"
errorCode=backend_unavailable
sessionId=sess_928fd02e-e471-4320-b73b-055c94f71e1e
traceId=1aa31a71-2d0b-44aa-84a9-d2f80444987c
9/1 全天无此错误(首次出现即故障起点)。系统 DiagnosticReports 与统一日志均无对应崩溃/挂起/内存事件。
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with ~/.zcode/cli/log/zcode-2026-09-02.jsonl and the browser.turn_screenshot.capture_failed entries containing errorCode=backend_unavailable. Reproduce the long-running Outlook Web scenario on macOS and compare screenshot, DOM, reload, and new-tab behavior. Done means the rendering backend recovers without restarting ZCode, or the failure is surfaced with a defined recovery path.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- macos
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Needs clarification
- Newbie friendliness
- 28/100