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

Error running tests on x86_64-darwin **only on CI** #9107

Open
Radvendii opened this issue Oct 6, 2023 · 0 comments
Open

Error running tests on x86_64-darwin **only on CI** #9107

Radvendii opened this issue Oct 6, 2023 · 0 comments
Labels

Comments

@Radvendii
Copy link
Contributor

Describe the bug

I've been trying to build nix in CI as a dependency for a nickel experimental feature, and am getting an error on the foldlPrime test on the x86_64-darwin builder. When I try to reproduce it on my local x86_64-darwin machine, there is no error.

  • Both are using nix 2.17.0.
  • The derivations in both cases are identical (i checked not only the store path but the contents).
  • This error has happened on multiple versions of Nix (i.e. i tried to update and that didn't fix it)

CI logs: https://github.com/tweag/nickel/actions/runs/6427208299/job/17452514550?pr=1465#step:5:4453

Relevant part:

nix> src/libexpr/tests/error_traces.cc:758: Failure
nix> Expected equality of these values:
nix>   e.info().traces.size()
nix>     Which is: 3
nix>   2
nix> while testing foldl' (a: b: a && b) "foo" [ true ]
nix> error:
nix>        … while calling the 'foldl'' builtin
nix>          at «string»:1:1:
nix>             1| builtins.foldl' (a: b: a && b) "foo" [ true ]
nix>              | ^
nix>        … while calling anonymous lambda
nix>          at «string»:1:21:
nix>             1| builtins.foldl' (a: b: a && b) "foo" [ true ]
nix>              |                     ^
nix>        error: value is a string while a Boolean was expected
nix> [  FAILED  ] ErrorTraceTest.foldlPrime (0 ms)

The error trace produced on my local machine, which matches what the test expects, is:

error:
        … while calling the 'foldl'' builtin
          at «string»:1:1:
             1| builtins.foldl' (a: b: a && b) "foo" [ true ]
              | ^
        … in the left operand of the AND (&&) operator
          at «string»:1:21:
             1| builtins.foldl' (a: b: a && b) "foo" [ true ]
              |                     ^
        error: value is a string while a Boolean was expected

Expected behavior

The tests should pass. But perhaps more concerning, nix builds should produce consistent results across different machines.

nix-env --version output

nix-env (Nix) 2.17.0 on both

Priorities

Add 👍 to issues you find important.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant