diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ecebe78eed..56ef0d26c2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -508,6 +508,7 @@ jobs: run: bash scripts/ci/install-workspace-dependencies.sh --ignore-scripts - name: Install dependencies if: runner.os == 'Windows' + shell: bash run: bash scripts/ci/install-workspace-dependencies.sh --ignore-scripts --linker=hoisted - run: bun run --cwd packages/cli test src/utils/npxCommand.test.ts src/commands/skills.test.ts diff --git a/examples/k8s-jobs/Dockerfile.example b/examples/k8s-jobs/Dockerfile.example index e35248125a..e386b8609b 100644 --- a/examples/k8s-jobs/Dockerfile.example +++ b/examples/k8s-jobs/Dockerfile.example @@ -105,7 +105,7 @@ COPY packages/engine/package.json packages/engine/ COPY packages/producer/package.json packages/producer/ # A corrupt tarball extraction can print an error and then hang instead of -# exiting (fix/regression-docker-build-timeout). Bound each attempt and retry. +# exiting (run 35468046055). Bound each attempt and retry. RUN npm install --global bun && \ (timeout 300 bun install --frozen-lockfile || timeout 300 bun install --frozen-lockfile) && \ npm uninstall --global bun diff --git a/scripts/ci/install-workspace-dependencies.sh b/scripts/ci/install-workspace-dependencies.sh index c7641cc7c9..55ab2f6164 100644 --- a/scripts/ci/install-workspace-dependencies.sh +++ b/scripts/ci/install-workspace-dependencies.sh @@ -18,7 +18,15 @@ run_with_timeout() { local elapsed=0 while kill -0 "$pid" 2>/dev/null; do if ((elapsed >= seconds)); then - kill -TERM "$pid" 2>/dev/null + # Git Bash's `kill -TERM` on a native Windows binary (bun.exe) is a + # best-effort thread-injection emulation, not a real signal, and can + # fail to land -- the exact hang this function exists to prevent. + # taskkill //T (kills the child tree) //F (TerminateProcess) is real. + if [[ "${OS:-}" == "Windows_NT" ]]; then + taskkill //F //T //PID "$pid" 2>/dev/null + else + kill -TERM "$pid" 2>/dev/null + fi wait "$pid" 2>/dev/null return 124 fi