!NhAsaYbbgmzHtXTPQJ:funklause.de

Nix NodeJS

177 Members
51 Servers

Load older messages


SenderMessageTime
25 Mar 2025
@marie:marie.cologneMarie changed their display name from Marie to Marie Ramlow.17:42:27
@marie:marie.cologneMarie changed their display name from Marie Ramlow to Marie.17:44:54
26 Mar 2025
@hexa:lossy.networkhexado we have a prefetcher for pnpm?20:43:36
@hexa:lossy.networkhexa asking for one out of date discourse, which we run on discourse.nixos.org 20:45:34
@hexa:lossy.networkhexahm, enoscrumplex20:48:13
@hexa:lossy.networkhexa
nix-repl> :b pnpm_9.fetchDeps { pname = "discourse"; src = /tmp/discourse; hash = ""; }
warning: found empty hash, assuming 'sha256-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA='
error: build of '/nix/store/i96hrd6k8k1d1kjccpkp9sqfdm1xwvlr-discourse-pnpm-deps.drv' on 'ssh://hexa@build1.darmstadt.ccc.de' failed: builder for '/nix/store/i96hrd6k8k1d1kjccpkp9sqfdm1xwvlr-discourse-pnpm-deps.drv' failed with exit code 1;
       last 8 log lines:
       > Running phase: unpackPhase
       > unpacking source archive /nix/store/9vkknlvpk9k2r13k1pa7xxfbnr8a7xrm-discourse
       > source root is discourse
       > Running phase: patchPhase
       > Running phase: updateAutotoolsGnuConfigScriptsPhase
       > Running phase: installPhase
       > yq: Error running jq: ScannerError: mapping values are not allowed in this context
       >   in "pnpm-lock.yaml", line 209, column 75.
       For full logs, run 'nix log /nix/store/i96hrd6k8k1d1kjccpkp9sqfdm1xwvlr-discourse-pnpm-deps.drv'.
20:56:43
@hexa:lossy.networkhexaah, my bad 😄 20:57:18
27 Mar 2025
@rosssmyth:matrix.orgrosssmyth

Hello. I have a pnpm+rsbuild package I am trying to build with nix. It used to build, but it does not any longer. I'm unsure in the exact change that has caused it, nor have my attempts at enabling logging actually enabled any useful logging. The error is:

> rsbuild build
>   Rsbuild v1.2.19
>
> 🧐  Checking for wasm-pack...
>
> ✅  wasm-pack is installed at /build/source/node_modules/.bin/wasm-pack.
>
> â„šī¸  Compiling your crate in release mode...
>
> Error fetching release: getaddrinfo EAI_AGAIN github.com
> 🧐  Checking for wasm-pack...
>
> ✅  wasm-pack is installed at /build/source/node_modules/.bin/wasm-pack.
>
> â„šī¸  Compiling your crate in release mode...
>
> Error fetching release: getaddrinfo EAI_AGAIN github.com
> 🧐  Checking for wasm-pack...
>
> ✅  wasm-pack is installed at /build/source/node_modules/.bin/wasm-pack.
>
> â„šī¸  Compiling your crate in release mode...
>
> Error fetching release: getaddrinfo EAI_AGAIN github.com
> ● web ━━━━━━━━━━━━━━━━━━━━━━━━━ (93%) sealing after asset optimization          error   Compile error:
> Failed to compile, check the errors for troubleshooting.

This is a TS project with some WASM. I poked around in the wasm pack plugin source and couldn't find where it may attempt to fetch some release.

Outside of the sandbox it builds fine.

Doing a bisect shows that three dependencies were added to the project in the commit that broke the sandboxed builds:

"devDependencies": {
"vitest": "^2.1.8",
"wasm-pack": "^0.13.1",
"webpack-glsl-loader": "github:grieve/webpack-glsl-loader"
21:25:06
@rosssmyth:matrix.orgrosssmyth *

Hello. I have a pnpm+rsbuild package I am trying to build with nix. It used to build, but it does not any longer. I'm unsure in the exact change that has caused it, nor have my attempts at enabling logging actually enabled any useful logging. The error is:

> rsbuild build
>   Rsbuild v1.2.19
>
> 🧐  Checking for wasm-pack...
>
> ✅  wasm-pack is installed at /build/source/node_modules/.bin/wasm-pack.
>
> â„šī¸  Compiling your crate in release mode...
>
> Error fetching release: getaddrinfo EAI_AGAIN github.com
> 🧐  Checking for wasm-pack...
>
> ✅  wasm-pack is installed at /build/source/node_modules/.bin/wasm-pack.
>
> â„šī¸  Compiling your crate in release mode...
>
> Error fetching release: getaddrinfo EAI_AGAIN github.com
> 🧐  Checking for wasm-pack...
>
> ✅  wasm-pack is installed at /build/source/node_modules/.bin/wasm-pack.
>
> â„šī¸  Compiling your crate in release mode...
>
> Error fetching release: getaddrinfo EAI_AGAIN github.com
> ● web ━━━━━━━━━━━━━━━━━━━━━━━━━ (93%) sealing after asset optimization          error   Compile error:
> Failed to compile, check the errors for troubleshooting.

This is a TS project with some WASM. I poked around in the wasm pack plugin source and couldn't find where it may attempt to fetch some release.

Outside of the sandbox it builds fine.

Doing a bisect shows that three dependencies were added to the project in the commit that broke the sandboxed builds:

"devDependencies": {
...
"vitest": "^2.1.8",
"wasm-pack": "^0.13.1",
"webpack-glsl-loader": "github:grieve/webpack-glsl-loader"
}
21:25:20
@rosssmyth:matrix.orgrosssmythIf anyone has any ideas as to what could be the issue or how to debug it further please let me know21:25:34
@rosssmyth:matrix.orgrosssmythMy initial thought was something with github dependencies, but creating a dummy project with only the webpack-glsl-loader dependency works fine21:26:20
@rosssmyth:matrix.orgrosssmythOk I removed the "wasm-pack" line in the package.json and it works21:31:08
@rosssmyth:matrix.orgrosssmythIt does complain that it is not able to download wasm-opt, but it does compile21:32:57
@rosssmyth:matrix.orgrosssmyth* It does complain that it is not able to download wasm-opt/binaryen, but it does compile21:33:07
@rosssmyth:matrix.orgrosssmyth Yeah it seems to be some sort of issue when wasm-pack is in the dependency tree. Even if I put it in the optional dependencies then give it --no-optional, the build fails because something seems to expect it to exist 22:04:54
@rosssmyth:matrix.orgrosssmythUpstream there are some issues open for this22:05:12
28 Mar 2025
@beviu:matrix.orgbeviu joined the room.14:55:15
@tweqx:matrix.orgtweqx joined the room.15:03:57
@beviu:matrix.orgbeviu Hi, we would like to package Overleaf based on work from an existing draft PR at https://github.com/NixOS/nixpkgs/pull/216889. One problem with Overleaf is that it has Git dependencies in its package.json file that have build scripts but do not have a package-lock.json file, and fetch-npm-deps doesn't support that (and rightly so, because it would not be reproducible). In that PR, the authors created a Python scripts that finds the Git dependencies in package.json, clones them, modifies the package.json to point to the clone, then run npm install to update the package-lock.json with the Git dependencies' transitive dependencies and commit that patched package-lock.json to Nixpkgs. We have a different idea where we would build the Git dependencies individually using buildNpmPackage, and then in the prePatch phase of Overleaf, we would modify the package-lock.json file in the prePatch phase to replace the Git dependencies with local dependencies that point to the output of the buildNpmPackage derivations. This would require modifying fetch-npm-deps to accept local dependencies (at least those that point to the Nix store in the form of "resolved": "/nix/store/..."). Do you think this would be the best approach? Would Nixpkgs accept a change to fetch-npm-deps to accept local dependencies? If so, maybe add a flag like --store-dir to fetch-npm-deps to tell it the location of the store (/nix/store) and only allow local dependencies under this directory? 15:12:13
@beviu:matrix.orgbeviu * Hi, we would like to package Overleaf based on work from an existing draft PR at https://github.com/NixOS/nixpkgs/pull/216889. One problem with Overleaf is that it has Git dependencies in its package.json file that have build scripts but do not have a package-lock.json file, and fetch-npm-deps doesn't support that (and rightly so, because it would not be reproducible). In that PR, the authors created a Python script that finds the Git dependencies in package.json, clones them, modifies the package.json to point to the clones, then runs npm install to update the package-lock.json with the Git dependencies' transitive dependencies and commit that patched package-lock.json to Nixpkgs. We have a different idea where we would build the Git dependencies individually using buildNpmPackage, and then in the prePatch phase of Overleaf, we would modify the package-lock.json file to replace the Git dependencies with local dependencies that point to the output of the buildNpmPackage derivations. This would require modifying fetch-npm-deps to accept local dependencies (at least those that point to the Nix store in the form of "resolved": "/nix/store/..."). Do you think this would be the best approach? Would Nixpkgs accept a change to fetch-npm-deps to accept local dependencies? If so, maybe add a flag like --store-dir to fetch-npm-deps to tell it the location of the store (/nix/store) and only allow local dependencies under this directory? 15:13:55
29 Mar 2025
@tweqx:matrix.orgtweqx It unfortunately turns out we cannot do this because the package-lock.json file contained in the npmDeps derivation will depend on the store path location, meaning that npmDepsHash won't fixed :(( 19:59:02
1 Apr 2025
@strum355:matrix.orgstroem changed their display name from stroem - sourcegraph to stroem.09:41:48
@sandro:supersandro.deSandro 🐧 changed their display name from Sandro 🐧 to Sandro 🐧 [c3d2].13:58:31
@sandro:supersandro.deSandro 🐧 changed their display name from Sandro 🐧 [c3d2] to Sandro 🐧.13:58:32
@tumble1999:matrix.orgTumble

bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/posts/updates/mm/mm-update-65/index.html from ./_posts/2023-08-31-mm-update-65.md (liquid)
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/blog/index.html from ./_lists/blog.md (liquid)
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/root/index.html from ./_lists/root.md (liquid)
bmod> [11ty] Writing /nix/store/sjl5mghgzs9hrhzkkjr4vwnmr02zd0dx-bmod-static/bmod/index.html from ./_lists/bmod.md (liquid)
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/bmod/index.html from ./_lists/bmod.md (liquid)
bmod> [11ty] Writing /nix/store/sjl5mghgzs9hrhzkkjr4vwnmr02zd0dx-bmod-static/mm/index.html from ./_lists/mm.md (liquid)
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/mm/index.html from ./_lists/mm.md (liquid)
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/documents/index.html from ./_lists/documents.md (liquid)
bmod> /nix/store/blp465c3ps5841lx2l1ip5qvpw74wb9r-npm-build-hook/nix-support/setup-hook: line 3: 276 Killed npm run ${npmWorkspace+--workspace=$npmWorkspace} "$npmBuildScript" $npmBuildFlags "${npmBuildFlagsArray[@]}" $npmFlags "${npmFlagsArray[@]}"
bmod> ERROR: npm build failed
bmod> Here are a few things you can try, depending on the error:
bmod> 1. Make sure your build script (static:build) exists
bmod> If there is none, set dontNpmBuild = true.
bmod> 2. If the error being thrown is something similar to "error:0308010C:digital envelope routines::unsupported", add NODE_OPTIONS = "--openssl-legacy-provider" to your derivation
bmod> See https://github.com/webpack/webpack/issues/14532 for more information.
error: builder for '/nix/store/3q5gmxkpwxpxbm9fr47ixyl6b4r0bgng-bmod.drv' failed with exit code 1
error: 1 dependencies of derivation '/nix/store/0qdymn0fajkb0ri1nsrgl4d3ncjhlqzl-Caddyfile.drv' failed to build
error: 1 dependencies of derivation '/nix/store/48b8rwdm9kigwa5bnjhab339zshrd6dl-unit-bmod-prod-webhook.service.drv' failed to build
error: 1 dependencies of derivation '/nix/store/65gqn3vqdyirxqag3mpfvyx78p5vphp3-Caddyfile-formatted.drv' failed to build
error: 1 dependencies of derivation '/nix/store/nxj1v1lq33k0nhbxp6vq3d08zlxy0hq3-etc.drv' failed to build
error: 1 dependencies of derivation '/nix/store/8cnb2wb3m3im4g936m8d48vg2qshmyhd-nixos-system-blutsauger-25.05.20250330.52faf48.drv' failed to build

why do i get this error when it doesnt seem like anything failed?

17:30:47
@tumble1999:matrix.orgTumble *
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/posts/updates/mm/mm-update-65/index.html from ./_posts/2023-08-31-mm-update-65.md (liquid)
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/blog/index.html from ./_lists/blog.md (liquid)
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/root/index.html from ./_lists/root.md (liquid)
bmod> [11ty] Writing /nix/store/sjl5mghgzs9hrhzkkjr4vwnmr02zd0dx-bmod-static/bmod/index.html from ./_lists/bmod.md (liquid)
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/bmod/index.html from ./_lists/bmod.md (liquid)
bmod> [11ty] Writing /nix/store/sjl5mghgzs9hrhzkkjr4vwnmr02zd0dx-bmod-static/mm/index.html from ./_lists/mm.md (liquid)
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/mm/index.html from ./_lists/mm.md (liquid)
bmod> [11ty] Writing /nix/store/a1bwpqqchlv5slmw8fn6bp0fxcqv42ds-bmod-static/documents/index.html from ./_lists/documents.md (liquid)
bmod> /nix/store/blp465c3ps5841lx2l1ip5qvpw74wb9r-npm-build-hook/nix-support/setup-hook: line 3:   276 Killed                  npm run ${npmWorkspace+--workspace=$npmWorkspace} "$npmBuildScript" $npmBuildFlags "${npmBuildFlagsArray[@]}" $npmFlags "${npmFlagsArray[@]}"
bmod> ERROR: `npm build` failed
bmod> Here are a few things you can try, depending on the error:
bmod> 1. Make sure your build script (static:build) exists
bmod>   If there is none, set `dontNpmBuild = true`.
bmod> 2. If the error being thrown is something similar to "error:0308010C:digital envelope routines::unsupported", add `NODE_OPTIONS = "--openssl-legacy-provider"` to your derivation
bmod>   See https://github.com/webpack/webpack/issues/14532 for more information.
error: builder for '/nix/store/3q5gmxkpwxpxbm9fr47ixyl6b4r0bgng-bmod.drv' failed with exit code 1
error: 1 dependencies of derivation '/nix/store/0qdymn0fajkb0ri1nsrgl4d3ncjhlqzl-Caddyfile.drv' failed to build
error: 1 dependencies of derivation '/nix/store/48b8rwdm9kigwa5bnjhab339zshrd6dl-unit-bmod-prod-webhook.service.drv' failed to build
error: 1 dependencies of derivation '/nix/store/65gqn3vqdyirxqag3mpfvyx78p5vphp3-Caddyfile-formatted.drv' failed to build
error: 1 dependencies of derivation '/nix/store/nxj1v1lq33k0nhbxp6vq3d08zlxy0hq3-etc.drv' failed to build
error: 1 dependencies of derivation '/nix/store/8cnb2wb3m3im4g936m8d48vg2qshmyhd-nixos-system-blutsauger-25.05.20250330.52faf48.drv' failed to build

why do i get this error when it doesnt seem like anything failed?

17:31:00
@tumble1999:matrix.orgTumble

it only happens in a nixos-rebuild switch and its random

but trying to iscolate things like testhing with nixos-rebuild build
or sepcifically doing nix-build on the node project specifically, things work fine

17:38:57
3 Apr 2025
@sandro:supersandro.deSandro 🐧mentions dmesg something? maybe oom?11:26:45
5 Apr 2025
@tinybronca:sibnsk.net@tinybronca:sibnsk.net removed their display name underpantsgnome.15:54:34
@tinybronca:sibnsk.net@tinybronca:sibnsk.net left the room.15:59:24

Show newer messages


Back to Room ListRoom Version: 6