fix: windows下执行spawn报错#517
Open
shijie-todd wants to merge 2 commits intozh-lx:nextfrom
Open
Conversation
Review Summary by QodoFix Windows spawn execution error for Claude CLI
WalkthroughsDescription• Fix Windows spawn execution error for Claude CLI • Normalize CLI path to use .cmd wrapper on Windows • Add shell option for .cmd/.bat/.ps1 execution • Improve path parsing with cross-platform line ending support Diagramflowchart LR
A["Windows where claude"] -->|finds| B["claude file without extension"]
B -->|normalizeClaudeCliPathForWindowsSpawn| C["claude.cmd wrapper"]
C -->|cliPathNeedsShellSpawnOnWindows| D["spawn with shell: true"]
D -->|success| E["CLI execution works"]
File Changes1. packages/core/src/server/ai-provider-claude.ts
|
Code Review by Qodo
1.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
name: windows下执行spawn报错
about: windows下执行spawn报错
插件版本
2.0.0-beta.6
Bug 类型
Bug 描述
使用AI Assistant功能,使用的是claude code 的cli模式,在对话框发送信息以后,控制台报错如下,原因是windows下执行where claude 找到的 claude文件不是spawn可以执行的文件,应该执行claude.cmd
系统
你使用的打包器及版本
你使用的 web 框架
自检信息
[√ ] 你的浏览器、IDE、代码是否在一台机器上(非远程开发机或者云开发机情况)
[√ ] 浏览器控制台是否有打印组合按键提示信息

[√ ] 页面 DOM 是否有注入

data-insp-path属性