Nodejs, nodejs_23, nodejs_22, etc. are always built locally

Hi all,

It happens regularly after update to latest nixos-24.11, that my PC starts to build nodejs locally.

This would take a night of 100% CPU and sometimes break up due to lack of memory.

…
[7/2069] CXX obj/deps/v8/src/base/v8_libbase.emulated-virtual-address-subspace.o
[8/2069] CXX obj/deps/v8/src/base/v8_libbase.file-utils.o
…

I wonder why it’s so often that Nix’ CI didn’t have a build binary in the cache?

In the current case, I have updated two days ago via npins to:

{
  "pins": {
    "nixpkgs": {
      "type": "Channel",
      "name": "nixos-24.11",
      "url": "https://releases.nixos.org/nixos/24.11/nixos-24.11.715057.5ef6c4259808/nixexprs.tar.xz",
      "hash": "1gj3jggb5f461vcirdah0faiiidps9a3vi9s3wg9rs4x2ghk273z"
    }
  }
}

And it still isn’t in the binary cache…

What should I do?

2 Likes
$ nix shell github:nixos/nixpkgs/5ef6c425980847c78a80d759abc476e941a9bf42#nodejs_23 -c node -v
v23.8.0
$ nix shell github:nixos/nixpkgs/5ef6c425980847c78a80d759abc476e941a9bf42#nodejs_22 -c node -v
v22.14.0

they are downloading from the binary cache for me. see if you can do it now?

1 Like

Both lines are building for me just now:

[1/0/1 built] building nodejs-22.14.0 (buildPhase): [16/2069] CXX obj/deps/v8/src/base/numbers/v8_libbase.fast-dtoa.o

Weired that they don’t build on your system.

For me, downloaded v23 from cache.nixos.org and v22 from nix-community.cachix.org

I have the same issue for nodejs_23, nodejs_22 and nodejs_21. nodejs_20 is being pulled from the binary cache.

updating the flakes fixed this issue

1 Like

Thanks all for your replies!

Yeah… with flake updated today it worked. I guess it’s just bad luck and bad timing if a version change is so new that it hasn’t yet built by CI.

@dtannock thank for the hint, I only have the default cache.nixos.org as binary cache but maybe I should add the one from cachix.org.