mirror of
https://github.com/affaan-m/everything-claude-code.git
synced 2026-07-02 04:51:26 +08:00
fix(ci): require clean probe exit for Windows shell/bash detection; add pyyaml dev dep
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
@@ -31,6 +31,7 @@ dev = [
|
||||
"pytest-mock>=3.12",
|
||||
"ruff>=0.4",
|
||||
"mypy>=2.1.0",
|
||||
"pyyaml>=6.0",
|
||||
]
|
||||
|
||||
[project.urls]
|
||||
|
||||
@@ -97,7 +97,10 @@ function findShellBinary() {
|
||||
windowsHide: true,
|
||||
timeout: 30000,
|
||||
});
|
||||
if (!probe.error) {
|
||||
// A candidate is only usable if it both spawns AND exits cleanly. The
|
||||
// Windows System32 bash.exe WSL launcher spawns without error but exits
|
||||
// non-zero when no distro is installed, so !probe.error alone is not enough.
|
||||
if (!probe.error && probe.status === 0) {
|
||||
_cachedShell = candidate;
|
||||
return _cachedShell;
|
||||
}
|
||||
@@ -118,7 +121,9 @@ function findBashBinary() {
|
||||
|
||||
for (const candidate of candidates) {
|
||||
const probe = spawnSync(candidate, ['-c', ':'], { stdio: 'ignore', windowsHide: true, timeout: 30000 });
|
||||
if (!probe.error) {
|
||||
// Require a clean exit, not just a successful spawn: the Windows System32
|
||||
// bash.exe WSL stub spawns fine but exits non-zero with no distro installed.
|
||||
if (!probe.error && probe.status === 0) {
|
||||
_cachedBash = candidate;
|
||||
return _cachedBash;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user