Skip to content

fix(聊天): 修复提问工具启动竞态 - #327

Merged
su-fen merged 3 commits into
Stack-Cairn:mainfrom
AlphaCatMeow:codex/fix-ask-user-question-race
Jul 30, 2026
Merged

fix(聊天): 修复提问工具启动竞态#327
su-fen merged 3 commits into
Stack-Cairn:mainfrom
AlphaCatMeow:codex/fix-ask-user-question-race

Conversation

@AlphaCatMeow

@AlphaCatMeow AlphaCatMeow commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Depends-On: none
Stack-Root: #327

改动说明

  • 将 AskUserQuestion 的可见发布时机延后到工具执行开始,确保用户看到卡片时挂起应答状态已经建立
  • 倒计时归零后统一禁用普通选项、其他输入和提交,避免过期答案覆盖超时结果
  • 保持桌面 GUI 与 Gateway WebUI 卡片逐字节镜像
  • 补充生命周期、Gateway 重连、超时回退、取消、立即应答、多问题和防重复提交回归测试

改动类型

  • Bug 修复
  • 新功能
  • 重构
  • 文档更新

测试说明

  • 定向回归测试:75/75
  • GUI production build
  • Gateway WebUI production build
  • Gateway WebUI 全量测试:493/493
  • 本次文件定向 Biome 检查
  • Mirror Check:116 个镜像文件通过
  • git diff --check
  • Playwright 390px / 412px 响应式与过期交互验证
  • Tauri 调试客户端手动验证 AskUserQuestion 立即应答、多问题和自定义答案

已知基线问题

  • GUI 全量前端测试为 1390/1395;5 项失败位于 mention 源码抽取和 provider preset 同步测试,与本 PR 文件无交集
  • GUI/WebUI 全量 lint 被仓库现有 CRLF formatter 基线拦截;本次修改文件的定向检查通过,仅保留组件原有的 2 条 ARIA 建议

关联 Issue

- 在工具执行开始时发布 AskUserQuestion,确保挂起状态先建立
- 倒计时归零后统一关闭选项、自定义输入和提交
- 补充生命周期、网关、超时与交互回归测试

@AlphaCatMeow AlphaCatMeow left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

倒计时归零硬禁用交互后,WebUI 的截止时间(桌面时钟盖章的绝对毫秒)
与本机 Date.now() 跨机器比较:浏览器时钟偏移超界会把仍在挂起的提问
卡一挂载就锁死。现仅当截止时间落在"挂载时刻~挂载时刻+完整应答窗口"
内才采信,否则回退挂载近似;过期提交仍由桌面挂起表权威拒绝。

@AlphaCatMeow AlphaCatMeow left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

收到,认可。

@su-fen
su-fen merged commit 82b366f into Stack-Cairn:main Jul 30, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants