Albert O'Shea
Albert O'Shea
Currently working on the github workflow to automatically update hashes of build deps in flake.nix. Any preferences around this, i.e. triggers or commits from bot?
Oh boy it was fun trying to get the node modules perfectly reproducible with Bun’s symlink tree, think I found a way though, it builds in github CI and on...
@rekram1-node Ready for reviewing/testing now (especially Mac+Nix users would be good) `nix run github:Alb-O/opencode/nix-support` For specific architectures: `nix run github:Alb-O/opencode/nix-support#packages.aarch64-linux.default` `nix run github:Alb-O/opencode/nix-support#packages.x86_64-linux.default` `nix run github:Alb-O/opencode/nix-support#packages.aarch64-darwin.default` `nix run github:Alb-O/opencode/nix-support#packages.x86_64-darwin.default`
> yields a different hash. Thank you for testing, these tiny, tiny, differences between the GitHub runner environment and actual user hardware that results in a different hash is driving...
Ok, may have found the culprit, hopefully this extra optional package pinning solves this. Please test again, same build/run commands as before
Ready to be tested again, models.dev API JSON is now sourced from nixpkgs, and I'm doing extra hash validation on other dependency packages Same commands as before: `nix run github:Alb-O/opencode/nix-support`...
Unfortunately, despite my best efforts, there are STILL sometimes random hash inconsistencies in the node_modules fixed output derivation between the github CI and local builds. The annoying part is it's...
> This has be working for me on NixOS (apart from the rewrite bugs that I assume are unrelated), has been consistent across multiple builds (I might be getting lucky)....
Here's proof of the CI run inconsistencies: [auto-commit on nix-support-dev branch](https://github.com/Alb-O/opencode/commit/22b928fb2085c64efc0f9cc443ade812d9f2ca67) [auto-commit on nix-support branch](https://github.com/Alb-O/opencode/commit/bbfa63da7b44ed5bc8f6d51d44139b7e13a7451c) The parent commit for both of these are identical (3c160aa), exact same git history up...
Hash inconsistency issues seem to be finally resolved, pinpointing the issue to symlinked binaries in `node_modules/.bun` and `.bin`, and normalizing these paths during nix builds. Looking nice and stable now...