fix(desktop): 隐藏远端设备加载失败提示 - #3797
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
| Filename | Overview |
|---|---|
| apps/desktop/src/renderer/features/cc-agent/CCAgentSidebarUpper.tsx | 删除设备目录错误提示和唯一手动重试入口后,独立 REST 瞬时失败可能使目录长期保持空或过期。 |
| apps/desktop/src/renderer/tests/dialogueSidebarSection.test.ts | 静态断言已与隐藏设备目录错误 UI 的预期同步,但没有覆盖失败后的恢复能力。 |
| apps/desktop/src/renderer/tests/machineSwitcherMenu.test.ts | 更新标题覆盖分支断言,明确设备目录 error 不再产生占位提示。 |
| apps/desktop/src/renderer/i18n/locales/en/common.json | 删除三项已无生产引用的设备目录失败与重试文案,其他语言文件保持同步。 |
Prompt To Fix All With AI
### Issue 1
apps/desktop/src/renderer/features/cc-agent/CCAgentSidebarUpper.tsx:3430
**设备目录失去恢复路径**
当 WebSocket 仍在线而设备目录 REST 请求单次返回 503 或网络错误,底层会进入 `error` 且不会定时重试;这里删除唯一的 `retryDeviceLinkDeviceList` 入口后,也没有状态事件保证再次刷新,导致远端设备目录一直为空或过期,直到无关状态变化或应用重启。
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.Reviews (1): Last reviewed commit: "fix(desktop): hide remote device load fa..." | Re-trigger Greptile
|
命中 UI 路径(apps/desktop/src/renderer/features/cc-agent/CCAgentSidebarUpper.tsx)但 description 未附界面效果证据——建议补充改动后效果:截图/录屏,或改动后界面的 HTML 页面(```html 代码块、.html 附件或在线预览链接),便于确认界面符合 DESIGN.md 设计规范。本次是隐藏远端设备加载失败提示,有侧栏相关截图更好。 |
|
已在 PR 描述的「UI 变化」补充自包含 HTML 示意,明确断网或远端设备目录失败时不显示错误卡片、红色告警或重试按钮,同时保留本地与缓存内容。 |
MagicLizi
left a comment
There was a problem hiding this comment.
代码重审通过:侧栏不再用设备目录失败告警打断本地/缓存内容;任务失败提示仍在。当前 head 没有 P0/P1。
c6806e4 to
8743074
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8743074cfb
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@dashhuang 👋 这个 PR 还有 1 条 review conversation 没 resolve(apps/desktop/src/renderer/features/cc-agent/CCAgentSidebarUpper.tsx),auto-review 因此暂时跳过、没法继续审查 / 合并。 如果你已经按评论改完或回应了,请到对应 thread 上点 Resolve conversation;全部 resolve 后,下一轮 auto-review 会自动重新审查这个 PR。 |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: aaf341a6c2
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@dashhuang 👋 这个 PR 还有 1 条 review conversation 没 resolve(apps/desktop/src/renderer/features/device-link/useDeviceLinkDeviceList.ts),auto-review 因此暂时跳过、没法继续审查 / 合并。 如果你已经按评论改完或回应了,请到对应 thread 上点 Resolve conversation;全部 resolve 后,下一轮 auto-review 会自动重新审查这个 PR。 |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: fc802c50bb
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b6b019b0f5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1f1d5a9765
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c659d04e63
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@dashhuang 👋 这个 PR 还有 1 条 review conversation 没 resolve(apps/desktop/src/renderer/features/device-link/useDeviceLinkDeviceList.ts),auto-review 因此暂时跳过、没法继续审查 / 合并。 如果你已经按评论改完或回应了,请到对应 thread 上点 Resolve conversation;全部 resolve 后,下一轮 auto-review 会自动重新审查这个 PR。 |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5a1edb7ad0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9d52b8e873
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@dashhuang 👋 这个 PR 还有 1 条 review conversation 没 resolve(apps/desktop/src/renderer/features/device-link/useDeviceLinkDeviceList.ts),auto-review 因此暂时跳过、没法继续审查 / 合并。 如果你已经按评论改完或回应了,请到对应 thread 上点 Resolve conversation;全部 resolve 后,下一轮 auto-review 会自动重新审查这个 PR。 |
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
9d52b8e to
cae9e9f
Compare
MagicLizi
left a comment
There was a problem hiding this comment.
独立代码审查通过:远端设备目录加载失败改为静默重试,任务失败告警仍保留。没有 P0/P1。
|
合了。设备目录加载失败不再弹一张吓人的错误卡,后台自己重试;真正的远端任务失败告警还在。 |
这次改了什么
摘要
远端设备目录属于侧栏的后台增强能力。断网或远端设备列表读取失败时,不再用错误卡片、红色告警或重试按钮打断侧栏,继续展示本地与已缓存内容;请求会在 renderer 内以 2 秒起步、指数退避、30 秒封顶的方式静默自动重试,成功后自动复位,不增加任何提示 UI;退避中的后台请求保持已结算的选择态,不反复触发侧栏 loading 占位。
变更类型
fix缺陷修复feat新功能refactor/perf重构或性能优化docs/test/chore文档、测试或工程维护范围
initialRequestSettled);同步静态与行为回归断言。远程与多端适配结论
listDevices请求;失败不会清空已有快照,也不触发 relay / peer teardown。online/connecting、presence 与 control-target 事件都可提前恢复,stopped会取消定时器并清空目录。后台重试保持已结算选择态,前台 loading 只由用户/状态事件触发。UI 变化
docs/design-rules/DESIGN.md§1 Visual Theme & Atmosphere(内容克制、只保留必要信息);§2 Color Palette & Roles(语义色仅用于必要状态信号)。本次移除非必要的设备目录错误卡片和红色告警,避免后台增强能力抢占用户注意力。UI 效果示意(Desktop)
断网或远端设备目录读取失败时,不渲染错误卡片、红色告警或重试按钮;读取中仅保留中性文字与轻量 spinner,不使用背景框;已有本地与缓存内容继续显示。该示意仅说明最终界面状态,不新增产品结构。
怎么验证的
自动验证
手工验证
不涉及:本轮未启动 Desktop 实机预览;改动通过静态回归和自动门禁验证。
未执行的验证
Desktop 实机目检未执行,原因是本轮只收敛已有失败提示逻辑,且当前会话未要求启动预览实例。
风险
风险分类
影响与回滚
提交前检查
git commit -s,见 DCO)