fix(acp): slash commands not showing during bootstrap#1949
Conversation
…mmands after bootstrap During ACP agent bootstrap, agent_status stream events are suppressed to prevent sidebar spinner noise. This also prevents the frontend acpStatus from updating, which means useSlashCommands never re-fetches after the initial empty result. Users see no slash command autocomplete until after their first message. Emit a dedicated slash_commands_updated event from onAvailableCommandsUpdate that bypasses the bootstrap filter. The frontend handler updates acpStatus to trigger a re-fetch of slash commands.
Code Review:fix(acp): slash commands not showing during bootstrap (#1949)变更概述本 PR 修复 ACP 平台在 bootstrap 阶段 slash 命令不显示的问题。由于 bootstrap 期间 方案评估结论:✅ 方案合理 方案准确定位了根本原因(bootstrap 期间 问题清单无阻塞性问题。 汇总
结论✅ 批准合并 — 实现正确,测试覆盖了后端发射逻辑及命令去重、过滤边界情况,代码干净无冗余。 本报告由本地 |
|
✅ 已自动 review,无阻塞性问题,正在触发自动合并。 |
Summary
agent_statusstream events are suppressed to prevent sidebar spinner noise, but this also prevents the frontendacpStatusfrom updatingacpStatusupdates,useSlashCommandsnever re-fetches after its initial empty result, so the slash command autocomplete menu stays emptyslash_commands_updatedIPC event emitted fromonAvailableCommandsUpdatethat bypasses the bootstrap filter and triggers the frontend to re-fetch commandsRelated Issues
Closes #1882
Test Plan
acpSlashCommandsUpdatedEvent.test.ts)