Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating HB to a non-master branch produces Nix error #372

Closed
geo2a opened this issue Nov 16, 2023 · 3 comments
Closed

Updating HB to a non-master branch produces Nix error #372

geo2a opened this issue Nov 16, 2023 · 3 comments

Comments

@geo2a
Copy link
Contributor

geo2a commented Nov 16, 2023

I've made a change to HB and wanted to check it in Booster's CI, so I ran ./scripts/update-haskell-backend.sh BRANCH, committed and pushed. The CI fails with:

error:
       … while calling the 'derivationStrict' builtin

         at /builtin/derivation.nix:9:12: (source not available)

       … while evaluating derivation 'ghc-shell-for-hs-backend-booster-0.0.0-0'
         whose name attribute is located at /nix/store/mbz4hixfgxq5b6vc0k3pp2iglcd4c353-source/pkgs/stdenv/generic/make-derivation.nix:303:7

       … while evaluating attribute 'NIX_GHC' of derivation 'ghc-shell-for-hs-backend-booster-0.0.0-0'

         at /nix/store/mbz4hixfgxq5b6vc0k3pp2iglcd4c353-source/pkgs/development/haskell-modules/generic-builder.nix:676:9:

          675|         LOCALE_ARCHIVE = lib.optionalString (stdenv.hostPlatform.libc == "glibc") "${buildPackages.glibcLocales}/lib/locale/locale-archive";
          676|         "NIX_${ghcCommandCaps}" = "${ghcEnv}/bin/${ghcCommand}";
             |         ^
          677|         "NIX_${ghcCommandCaps}PKG" = "${ghcEnv}/bin/${ghcCommand}-pkg";

       (stack trace truncated; use '--show-trace' to show the full trace)

       error: Cannot find Git revision '59b5b34de1119d3da2d3b9cc2a4ffd2abbddb571' in ref 'refs/heads/master' of repository 'https://github.com/runtimeverification/haskell-backend.git'! Please make sure that the rev exists on the ref you've specified or add allRefs = true; to fetchGit.

The relevant part seems to be at the end: Cannot find Git revision '59b5b34de1119d3da2d3b9cc2a4ffd2abbddb571' in ref 'refs/heads/master' of repository 'https://github.com/runtimeverification/haskell-backend.git'! Please make sure that the rev exists on the ref you've specified or add allRefs = true; to fetchGit. Here's the CI run.

I have not running nix build locally, but I did try kup install kontrol --override BOOSTER BRANCH, and that gives the same error.

Perhaps we need to give some more parameters to stacklock2nix? Or modify the lock file itself in a different way?

@goodlyrottenapple
Copy link
Member

Here is the issue in stacklock2nix: cdepillabout/stacklock2nix#38

@goodlyrottenapple
Copy link
Member

A temporary fix has been merged in #376, however, we should keep this issue open and revert #376, if/when cdepillabout/stacklock2nix#38 is resolved.

@goodlyrottenapple goodlyrottenapple removed their assignment Nov 20, 2023
@geo2a
Copy link
Contributor Author

geo2a commented Dec 5, 2023

stacklock2nix has been update and the workaround has been reverted: #407

@geo2a geo2a closed this as completed Dec 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants