### 问题描述 在使用 CodePilot 时发现,输入框的 `/` 快捷指令补全功能在读取项目本地(Local)的 Claude Code Skills 时存在两个独立的 Bug: #### Bug 1:基于文件的本地指令(如 `opsx`)存在上下文同步/刷新滞后 - **现象**:在旧对话中输入 `/ops` 无法补全 `.claude/commands/opsx/` 目录下的指令。 - **临时方案**:点击“New Chat”创建一个新会话,新会话里就能补全了。此时切回旧会话,旧会话也随之恢复。 - **原因推测**:CodePilot 读取本地 `commands` 目录的机制存在缓存,依赖新建会话来触发扫描,旧会话无法自动实时热更新。 #### Bug 2:完全无法读取基于配置的插件指令(如 `superpowers`) - **现象**:无论如何操作,补全列表始终找不到 `superpowers` 系列指令(如 `/writing-plans` 等)。 - **根本原因**:经过排查发现,`opsx` 是通过本地 Markdown 文件定义的,而 `superpowers` 是在 `.claude/settings.json` 中通过 `"enabledPlugins": { "superpowers@claude-plugins-official": true }` 启用的官方插件。 - **对比**:原生 Claude Code 终端能正确读取该 json 配置并注入指令,但 CodePilot 似乎只扫描了 `commands` 文件夹,遗漏了对 `settings.json` 中插件字段的解析。 ### 复现步骤 1. 在项目下配置 `.claude/commands/` 目录及 `settings.json`(启用 superpowers 插件)。 2. 在 CodePilot 输入框中测试 `/` 指令补全。 3. 观察旧会话与新会话的差异,以及官方插件指令的缺失。 ### 预期行为 1. 保证当前工作目录下的新旧会话都能实时、一致地读取本地 `commands` 指令。 2. 自动补全逻辑应包含对 `.claude/settings.json` 中 `enabledPlugins` 字段的解析。 ### 截图说明 **Bug1 相关图片**: - 旧会话未识别openspec命令 <img width="2560" height="1380" alt="Image" src="https://github.com/user-attachments/assets/02f78b55-9bce-4cb5-91c1-0742c271e716" /> - 新会话可以识别 <img width="2560" height="1380" alt="Image" src="https://github.com/user-attachments/assets/08086523-3137-4786-a1b6-de1eaea46404" /> - 旧会话也刷新了 <img width="2560" height="1380" alt="Image" src="https://github.com/user-attachments/assets/48e0ffcd-ef67-4b43-aad7-5c6b538ae868" /> **Bug2 相关图片**: - 未识别到superpowers命令 <img width="2560" height="1380" alt="Image" src="https://github.com/user-attachments/assets/8bc137ff-7b20-429e-84c5-8d26c5881c19" /> - 本地Claude Code可以识别到,以及本地的一些配置 <img width="2560" height="1380" alt="Image" src="https://github.com/user-attachments/assets/e8042482-7f0c-4ee1-9af0-1ce3b3d76927" /> ### 环境信息 - CodePilot 版本: v0.50.3 - Claude Code 版本: v2.1.110
问题描述
在使用 CodePilot 时发现,输入框的
/快捷指令补全功能在读取项目本地(Local)的 Claude Code Skills 时存在两个独立的 Bug:Bug 1:基于文件的本地指令(如
opsx)存在上下文同步/刷新滞后/ops无法补全.claude/commands/opsx/目录下的指令。commands目录的机制存在缓存,依赖新建会话来触发扫描,旧会话无法自动实时热更新。Bug 2:完全无法读取基于配置的插件指令(如
superpowers)superpowers系列指令(如/writing-plans等)。opsx是通过本地 Markdown 文件定义的,而superpowers是在.claude/settings.json中通过"enabledPlugins": { "superpowers@claude-plugins-official": true }启用的官方插件。commands文件夹,遗漏了对settings.json中插件字段的解析。复现步骤
.claude/commands/目录及settings.json(启用 superpowers 插件)。/指令补全。预期行为
commands指令。.claude/settings.json中enabledPlugins字段的解析。截图说明
Bug1 相关图片:
Bug2 相关图片:
环境信息