bun icon indicating copy to clipboard operation
bun copied to clipboard

Randomly hangs on bun install (0.1.10)

Open yvg opened this issue 3 years ago • 1 comments

Version

0.1.10

Platform

Darwin box.local 20.4.0 Darwin Kernel Version 20.4.0: Thu Apr 22 21:46:47 PDT 2021; root:xnu-7195.101.2~1/RELEASE_X86_64 x86_64

What steps will reproduce the bug?

  1. If it already exists, remove the node_modules folder : rm -rf node_modules in a given repo.
  2. If it already exists, remove the bun installs cache: rm -rf ~/.bun/install/cache.
  3. Run bun install in a given repo.

How often does it reproduce? Is there a required condition?

It always reproduces, in previous versions it sometimes worked, but in 0.1.10 it has not worked so far.

What is the expected behavior?

bun install should complete the installation.

What do you see instead?

bun install hangs and it does not seem to hang on a particular dependency.

I've logged the output of three different tries from the same repo, the outputs seem different in size with no clear issue to me, here are the gists:

  • https://gist.github.com/yvg/e4cdcde66133a1b84eab87b38de93740
  • https://gist.github.com/yvg/184fd97dec3f405869d46824f9cf07e4
  • https://gist.github.com/yvg/3683a47aa389298a309d5d96f79255d2 (note: this is an install without removing the cache)

Additional information

One of the dependencies relies on a private registry in github, I am using a bunfig.toml file to configure the registry:

[install.scopes]

"@tooltime2019" = {token = "--REDACTED--", url = "https://npm.pkg.github.com"}

The Bearer token is outputted by the --verbose flag, I have redacted the token for obvious security reasons, and replaced it with the --REDACTED-- string in the logs.

In addition, I've tried a run without the package from the private registry. It sadly hangs too.

yvg avatar Aug 20 '22 18:08 yvg

I have the same issue in a repository built with github actions, running into a timeout while trying to install the dependencies. Going back to version 0.1.8 successfully installs.

whjvenyl avatar Aug 24 '22 08:08 whjvenyl

Can't reproduce this in 0.1.13, so I'll close this issue.

yvg avatar Sep 23 '22 09:09 yvg

I'm now getting this again as of bun 1.0.28/29

ThatOneCalculator avatar Feb 26 '24 05:02 ThatOneCalculator

Still occurs, tried completely erasing/reinstalling bun, node_modules, testing multiple projects, etc

ThatOneCalculator avatar Feb 27 '24 22:02 ThatOneCalculator

Still occurs, tried completely erasing/reinstalling bun, node_modules, testing multiple projects, etc

can you try with --ignore-scripts? if it doesn't hang it might be a bug with bun running lifecycle scripts

dylan-conway avatar Feb 27 '24 22:02 dylan-conway

Still occurs with --ignore-scripts, and hangs randomly each time it's restarted.

ThatOneCalculator avatar Feb 27 '24 22:02 ThatOneCalculator

Still getting this even as of 1.0.30

ThatOneCalculator avatar Mar 09 '24 21:03 ThatOneCalculator

.......never mind. It was DNS :facepalm:

ThatOneCalculator avatar Mar 09 '24 21:03 ThatOneCalculator