Repository navigation
[bun install] Fix race condition when error occurs while extracting tarballs - #19751
Merged
Merged
Conversation
Collaborator
|
Updated 2:14 AM PT - May 19th, 2025
✅ @Jarred-Sumner, your commit c14f46d8f2728ccdc0719159916b1f75f54c9374 passed in 🧪 To try this PR locally: bunx bun-pr 19751That installs a local version of the PR into your bun-19751 --bun |
dylan-conway
approved these changes
May 19, 2025
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.
What does this PR do?
This fixes a race condition when an error occurs while extracting tarballs caused by re-using the package manager's logger.Log while on a different thread.
This also adds
BUN_FEATURE_FLAG_DISABLE_INSTALL_INDEX.This also makes bun install exit with a non-zero status code when failing to install packages where before we would only do that sometimes. I'm not totally sure if that's the right call.
How did you verify your code works?
This could use a test. One interesting thing: we now duplicate error messages more consistently. We should remove the duplicate error too.