Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

node or yarn is broken on nixos-unstable, can't install pacakges, /bin/sh: bad interpreter: Text file busy #314713

Closed
anpin opened this issue May 25, 2024 · 10 comments
Labels
0.kind: bug Something is broken

Comments

@anpin
Copy link
Contributor

anpin commented May 25, 2024

Describe the bug

After updating a flake to latest nixos-unstable branch today yarn is not able to install packages.

Steps To Reproduce

nix-shell -I nixpkgs=channel:nixos-unstable -p nodejs yarn --run 'mkdir -p /tmp/test && cd /tmp/test && yarn init -y && yarn add esbuild && node -e "console.log(require(\"esbuild\"));"'
yarn init v1.22.22
warning The yes flag has been set. This will automatically answer yes to all questions, which may have security implications.
success Saved package.json
Done in 0.02s.
yarn add v1.22.22
warning package.json: "test" is also the name of a node core module
info No lockfile found.
warning test@1.0.0: "test" is also the name of a node core module
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
error /tmp/test/node_modules/esbuild: Command failed.
Exit code: 126
Command: node install.js
Arguments:
Directory: /tmp/test/node_modules/esbuild
Output:
/bin/sh: /run/user/1000/yarn--1716678098721-0.18406973672680782/node: /bin/sh: bad interpreter: Text file busy
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.

Expected behavior

yarn install succeeds

Additional context

Running against older version of nixpkgs works as well as nix build for this app

Notify maintainers

@offlinehacker @screendriver @marsam

Metadata

Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.

 - system: `"x86_64-linux"`
 - host os: `Linux 6.9.1, NixOS, 24.11 (Vicuña), 24.11.20240525.539e326`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.18.2`
 - channels(a): `"nixpkgs"`
 - channels(root): `"nixos"`
 - nixpkgs: `/home/a/.nix-defexpr/channels/nixpkgs`

Add a 👍 reaction to issues you find important.

@anpin anpin added the 0.kind: bug Something is broken label May 25, 2024
@wackbyte
Copy link
Contributor

wackbyte commented May 26, 2024

I am also experiencing this (with pnpm).

@robert-elles
Copy link
Contributor

Same issue here

@anpin
Copy link
Contributor Author

anpin commented May 26, 2024

Reverting both yarn and node to commits from last year doesn't solve the issue

@honnip
Copy link
Contributor

honnip commented May 26, 2024

@marsam
Copy link
Contributor

marsam commented May 26, 2024

maybe it's an issue with uring(?).
Can you try using export UV_USE_IO_URING=0 to confirm it?

@eliraz-refael
Copy link

I can confirm that using export UV_USE_IO_URING=0 works and solves the issue for me, at least.

@ncn-ends
Copy link

ncn-ends commented May 27, 2024

Had the same problem and export UV_USE_IO_URING=0 worked for me as well. Thank you

@ivan770
Copy link
Member

ivan770 commented Jun 3, 2024

With kernel 6.9.3 available on nixos-unstable this problem should no longer occur.

@anpin
Copy link
Contributor Author

anpin commented Jun 3, 2024

would love to try, but after rebasing to latest nixos-unstable today my system fails to start :(

@doronbehar
Copy link
Contributor

I'm closing as this is seems fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0.kind: bug Something is broken
Projects
None yet
Development

No branches or pull requests

9 participants