| 8 Nov 2023 |
szucsitg | Actually it is just the host name, I guess the pasting screwed up | 16:18:24 |
Lily Foster | Here's a wild shot in the dark -- did you invalidate the npmDepsHash and try to rebuild after adding the NIX_NPM_TOKENS? | 16:18:58 |
Lily Foster | Also that env.NIX_NPM_TOKENS is on the fetcher derivation, right? | 16:19:09 |
Lily Foster | (not buildNpmPackage) | 16:19:15 |
szucsitg | I invalidated the hash, but I'm not sure how could I override the fetcher | 16:19:44 |
Lily Foster | so you could add your own npmDepsHash | 16:20:21 |
Lily Foster | But I think you could hack it in postPatch | 16:20:29 |
Lily Foster | like postPatch = "export NIX_NPM_TOKENS=..."; on buildNpmPackage because that gets inherited into the fetcher | 16:20:42 |
Lily Foster | (env does not) | 16:20:46 |
Lily Foster | * so you could add your own npmDeps | 16:25:32 |
szucsitg | I first tried the postpatch but eval failed on it, I just realized I used the wrong quote in export 🤦♂ | 16:27:02 |
szucsitg | Thanks for helping me out, this did the trick | 16:27:19 |
szucsitg | I spent two days to figure out this, and couldn't | 16:28:22 |
Lily Foster | Awesome, glad that worked! | 16:29:21 |
Lily Foster | Let me know if you have other issues with it | 16:29:27 |
| 9 Nov 2023 |
| wisw joined the room. | 14:27:08 |
szucsitg | I am trying to build a frontend with mkYarnPackage but it fails on download for this lockfile
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
# yarn lockfile v1
"duo_web_sdk@https://github.com/duosecurity/duo_web_sdk#v2.9":
version "2.7.0"
resolved "https://github.com/duosecurity/duo_web_sdk#378e855ce4a1de1d1b2f7fd60465e564b3e9fbda"
The error is:
error: hash mismatch in fixed-output derivation '/nix/store/yxmkgwcrvzfmhhxjqkrcnd49fr8fv1bi-duosecurity_duo_web_sdk.drv':
specified: sha1-N46FXOSh3h0bL3/WBGXlZLPp+9o=
got: sha1-DbsHW3BaLQrtZoh0x5znwdK9xAc=
I'm not sure why the hash doesn't align | 15:29:00 |
Cobalt | That looks interesting, Have you tried to refresh the npmDeps Hash? | 15:34:42 |
szucsitg | I'm not defining it's just:
mkYarnPackage {
name = "node-modules";
src=./.;
} | 15:40:15 |
Lily Foster | In reply to @szucsitg:matrix.org
I am trying to build a frontend with mkYarnPackage but it fails on download for this lockfile
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
# yarn lockfile v1
"duo_web_sdk@https://github.com/duosecurity/duo_web_sdk#v2.9":
version "2.7.0"
resolved "https://github.com/duosecurity/duo_web_sdk#378e855ce4a1de1d1b2f7fd60465e564b3e9fbda"
The error is:
error: hash mismatch in fixed-output derivation '/nix/store/yxmkgwcrvzfmhhxjqkrcnd49fr8fv1bi-duosecurity_duo_web_sdk.drv':
specified: sha1-N46FXOSh3h0bL3/WBGXlZLPp+9o=
got: sha1-DbsHW3BaLQrtZoh0x5znwdK9xAc=
I'm not sure why the hash doesn't align what is the hash in the lockfile? it's not in your snippet | 15:43:29 |
szucsitg | If you start a new yarn project it's getting added like this 🤷 | 15:45:33 |
Lily Foster | Is that the entire file? | 15:46:13 |
szucsitg | Yes, that's my full test repo lock file. The original project has like 3k deps, I'm trying to isolate the issue | 15:47:05 |
Lily Foster | In reply to @szucsitg:matrix.org I'm not defining it's just:
mkYarnPackage {
name = "node-modules";
src=./.;
} And this is your entire derivation? | 15:47:56 |
szucsitg | No, it's not. But it doesn't get to mkDerivation that would depend on the node-modules | 15:48:57 |
szucsitg | I can upload the sample if that would help | 15:52:44 |
szucsitg | The funny thing I get a different hash in my test project than in my original for the very same lines in the lockfile | 15:53:34 |
szucsitg | Actually it's keeps changing as I scroll back | 15:54:25 |
Lily Foster | In reply to @szucsitg:matrix.org I can upload the sample if that would help yeah that probably would help. i'm trying to figure out where that hash is coming from at all | 15:56:38 |
szucsitg | https://gist.github.com/szucsitg/70fe7ca82c51d30208595cd04b8bd7c5 | 16:05:24 |