Mic92 / nixpkgs-review

Review pull-requests on https://github.com/NixOS/nixpkgs
MIT License
353 stars 59 forks source link

Fails to run in pure evaluation mode #355

Closed soispha closed 10 months ago

soispha commented 10 months ago

How to reproduce

  1. Add nix.pure-eval = true to your nixos-config (or add pure-eval = true in nix.conf).
  2. Every try to run nixpkgs-review will now fail, as access to the nixpath (<nixpkgs>) is forbidden.

Possible fixes

Implementing the second idea would probably necessitate adding a hash backed builtins.fetchTarball call, or something like it, to get access to nixpkgs.

Mic92 commented 10 months ago

I don't think you can have this set globally and still expects all tools to work properly. This should be only set on a cli level.

Mic92 commented 10 months ago

We are already passing --impure to nix and use --nix-path instead of '<nixpkgs>'.

Mic92 commented 10 months ago

I don't want to also add workarounds for this configuration. This would also break normal nix-shell usage and co. Don't do it or live with the consequences.