feat(desktop): add shell-ball direct error intake prompt#470
Conversation
| || isShellBallClipboardPromptActive(clipboardPrompt) | ||
| || isShellBallErrorPromptActive(errorPrompt); | ||
|
|
||
| const refreshErrorPromptFromForegroundWindow = useCallback(async () => { |
There was a problem hiding this comment.
Medium: getActiveWindowContext() resolves asynchronously, but this callback always commits the result. If the pointer leaves the shell-ball, the visual state changes, or a higher-priority selection/clipboard prompt appears before the promise settles, the stale response still calls setErrorPrompt(...) and resurrects an error opportunity that should already be suppressed. Please add a cancellation/request-token guard so only the latest eligible refresh can update state.
| * Error opportunities should stay as an explicit shell-ball-local prompt | ||
| * until the user confirms that the current failure context should become a | ||
| * formal `error_detected` task. | ||
| */ |
There was a problem hiding this comment.
Low: this PR wires the missing near-field error_detected UI path into the real shell-ball flow, but docs/work-priority-plan.md still leaves the corresponding checklist items unchecked (P0-B line 160 and the atomic task at line 324). The repo rules require updating that source-of-truth document in the same change once the feature is actually implemented.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
|
@xgopilot 目前悬浮球是怎么识别错误信息的? |
回复目前这版悬浮球的“错误识别”是前端本地规则匹配,不是模型判断,也不是 OCR/截图分析。
所以可以把现在的逻辑理解成:前台窗口标题命中错误关键词 -> 弹出本地提示气泡 -> 用户确认后再进入正式 当前没有做的事情也很明确:不读窗口正文、不读终端输出区、不做 OCR、不做语义分类;误报/漏报主要取决于窗口标题里有没有这些关键词。 |
…l-ball-error-intake-clean
61b74d3 to
16d0b04
Compare



Summary
Analyze errorandNot nowactionsagent.task.start(trigger = error_detected)and reuse the existing bubble/runtime/delivery task flowScope
error_detectedintake path from 任务:接入错误信息承接,统一 error_detected 与错误机会推荐入口 #389Validation
corepack pnpm --dir apps/desktop typecheckcorepack pnpm --dir apps/desktop lint(existingreact-refresh/only-export-componentswarnings only)corepack pnpm --dir apps/desktop test:shell-ballis currently blocked by an unrelated baseline error atapps/desktop/src/features/shell-ball/components/floating-pet/FloatingPet.tsx:152(repeatTypeimplicitly hasany)