wezterm icon indicating copy to clipboard operation
wezterm copied to clipboard

Nix Github Action / Cachix issue

Open ninelore opened this issue 10 months ago • 4 comments

~~Seems like no binaries are being pushed to Cachix atm.~~

For some reason the CI builds a different derivation than what is built when locally checking out

ninelore avatar Feb 19 '25 13:02 ninelore

Last CI Build: https://github.com/wezterm/wezterm/actions/runs/13321791697/job/37207677029#step:7:1644

❯ git rev-parse HEAD
ee0c04e735fb94cb5119681f704fb7fa6731e713
❯ nix eval .#default.outPath
"/nix/store/wbmmbq7hqsbkjkvp3r3ns3zjvbyhgs6g-wezterm"
❯ curl https://wezterm.cachix.org/wbmmbq7hqsbkjkvp3r3ns3zjvbyhgs6g.narinfo
404 - Not Found
❯ # Cached output by CI
❯ curl https://wezterm.cachix.org/8rhk2l27s586xl92hxn52dfgyk32h8gs.narinfo
StorePath: /nix/store/8rhk2l27s586xl92hxn52dfgyk32h8gs-wezterm
URL: nar/82e4a65171fa4fbe05abdf4b9ede55bfe6be7f500a4c011c70318f3588f48915.nar.zst
Compression: zstd
FileHash: sha256:82e4a65171fa4fbe05abdf4b9ede55bfe6be7f500a4c011c70318f3588f48915
FileSize: 58411765
NarHash: sha256:0w7463zr3470rkk1rx5l2dfj965hdf5728jnpkrw91rj37zpqhw1
NarSize: 167793248
References: 108rkb6zvfij7h9q1fqazmvdqrcp9wm8-vulkan-loader-1.3.296.0 2j3c18398phz5c1376x2qvva8gx9g551-libxcb-1.17.0 4fgxx1rc4x9vzzylyd192nkzb2ahva1p-libxkbcommon-1.7.0 4vmlxm1pqgphcq6326ff5c
z8ycawaagc-wayland-1.23.1 5mb70vg3kdzkyn0zqdgm4f87mdi0yi4i-libglvnd-1.7.0 65h17wjrrlsj2rj540igylrx7fqcd6vq-glibc-2.40-36 863q84pq0snljzmxrzij3c2zi2781mk1-wezterm-terminfo ag08lr0azw1chwigxx3
vlhiafp89ykhy-xcb-util-image-0.4.1 bpq1s72cw9qb2fs8mnmlw6hn2c7iy0ss-gcc-14-20241116-lib cqlaa2xf6lslnizyj9xqa8j0ii1yqw0x-zlib-1.3.1 h1ydpxkw9qhjdxjpic1pdc2nirggyy6f-openssl-3.3.2 ihxnkx03ysx
ha05iy81rlpznd46chs4d-xcb-util-0.4.1 nlqind4szw3amcmhgy4pd2n0894558gg-libX11-1.8.10 rbv8d3qlvfij22qiarxbfy4z8b4j9dr6-fontconfig-2.15.0-lib
Deriver: l74w3wgvins74shr2pa0zvrsxg9rlmdx-wezterm.drv
Sig: wezterm.cachix.org-1:QKHthTMw7+5Cu9q0cv8IeLaa6NYeGTflrDdG6o3CkEWiVh2aLLrU1dul1dUV1wUqyRqI5acHYiaRLiyhOdqnDA==
❯

ninelore avatar Feb 19 '25 14:02 ninelore

ok seem to only affect latest commit, might resolve itself once something is commited again

ninelore avatar Feb 19 '25 14:02 ninelore

is there still an issue with this?

wez avatar May 17 '25 16:05 wez

The cachix hasn't been working properly for me for a while, I always figured it was something wrong with my own config but I can never get my system to pull binaries from cachix.

EDIT: For clarity's sake, relevant parts of my system config are:

configuration.nix:

  environment.systemPackages = with pkgs; [
    inputs.wezterm.packages.${pkgs.system}.default
  ];

flake.nix:

  inputs = {
    wezterm.url = "github:wezterm/wezterm?dir=nix";
  };
  nixConfig = {
    extra-substituters = [
      "https://wezterm.cachix.org"
    ];

    extra-trusted-public-keys = [
      "wezterm.cachix.org-1:kAbhjYUC9qvblTE+s7S+kl5XM1zVa4skO+E/1IDWdH0="
    ];
  };

And I don't overwrite wezterm.inputs at all, and system is x86_64-linux. Some dependencies do hit the cachix, but wezterm still decides to compile from source every time.

Presumably this is because of this issue? The github action does build a version of wezterm, but it has a different SHA hash to what you get when you build locally.

EDIT 2: I've been trying to pull the .drv file from the cachix to compare to my local one, but with no luck: nix-store -r /nix/store/7d6ap5piy79vrl4s31215vcg8q0qv2dg-wezterm.drv (the most recent derivation) gives:

don't know how to build these paths:
  /nix/store/7d6ap5piy79vrl4s31215vcg8q0qv2dg-wezterm.drv
error: cannot build missing derivation '/nix/store/7d6ap5piy79vrl4s31215vcg8q0qv2dg-wezterm.drv'

Is there any way to pull this file from the cachix? Doesn't seem to be cached after the end of the process. Note that the hash that the remote derivation provides is different to the local one - so that's where the issue is coming from.

Jackaed avatar May 20 '25 16:05 Jackaed

I'm still encountering this now; building wezterm from nix requires actually building it. The wezterm cachix isn't giving anything...

SuperKenVery avatar Jul 22 '25 15:07 SuperKenVery