fix: fall back to tar install without hanging when package-manager install fails - #114
Open
zkochan wants to merge 2 commits into
Open
fix: fall back to tar install without hanging when package-manager install fails#114zkochan wants to merge 2 commits into
zkochan wants to merge 2 commits into
Conversation
…stall fails - Terminate pnpm's workers and stop the reporter even when the registry installation fails, so the process can exit after the tar fallback completes (previously CI jobs hung until killed by a no-output timeout). - Abort the package-manager installation if it takes longer than 60 seconds and fall back to installing from a tar file. - Print the reason when falling back to the tar method. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
fetchNode also runs actions in pnpm workers, so even a tar-method installation that downloads Node.js left the process hanging after completion. Terminate the workers when installVersion finishes, regardless of the installation method. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Problem
When `--method=package-manager` installation failed (e.g. `ERR_PNPM_TARBALL_INTEGRITY` in CI), the fallback to the tar method ran and succeeded — but the process never exited, so CI jobs hung until killed by a 10-minute no-output timeout, making the whole install look like a failure.
Two separate leaks kept the event loop alive:
There was also no upper bound on how long the package-manager method could take: if pnpm hung instead of throwing, the tar fallback was never reached.
Changes
Verification (run from the compiled bundle with an isolated `BVM_GLOBALS_DIR`)
🤖 Generated with Claude Code