Skip to content

Conversation

@lheckemann
Copy link
Member

@lheckemann lheckemann commented Oct 31, 2022

Pure evaluation should cover all the uses for restrict-eval, and restrict-eval currently breaks accessing Git inputs on Flakes1.

@lheckemann
Copy link
Member Author

Draft, because:

  • I'm not 100% confident that there's nothing that works in pure-but-not-restricted eval but shouldn't work in the context of Hydra
  • This results in Flake evals being able to access the local filesystem and arbitrary URLs if pure evaluation mode is disabled, which is a significant change from before

Pure evaluation should cover all the uses for restrict-eval, and
restrict-eval currently breaks accessing Git inputs on Flakes[1].

[1]: NixOS/nix#7098
@lheckemann lheckemann force-pushed the no-restrict-eval-for-flakes branch from 148a086 to 9370b0e Compare October 31, 2022 12:16
@lheckemann lheckemann marked this pull request as ready for review November 2, 2022 10:18
@lheckemann
Copy link
Member Author

I think it's OK to do this. People disabling pure evaluation presumably have a good reason to do so.

@edolstra
Copy link
Member

This does open up access to path flakes in the local file system (e.g. by having a flake input path:/foo/bar), see EvalState::checkURI().

@lheckemann
Copy link
Member Author

In that case, I guess fixing NixOS/nix#7098 in Nix is the right approach to solving this problem.

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

Successfully merging this pull request may close these issues.

2 participants