1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2024-09-19 10:50:24 -04:00

doc: Manage expectations for eval-cache

Incorrectly high expectations lead to frustration for users who
stick around to experience how useless it is for e.g. a devShell

https://functional.cafe/@arianvp/112976284363120036:

> Flakes doesn't have eval caching. It has command line argument
> caching. It literally just stores the cli argument you passed
> in a sqlite database and yes that's as useless as it sounds

> When I discovered flakes had no expression level caching whatsoever
> I kind of felt lied to and betrayed.
This commit is contained in:
Robert Hensing 2024-08-17 13:34:45 +02:00
parent 31f3f23ee6
commit b52e58903e
2 changed files with 7 additions and 1 deletions

View file

@ -141,6 +141,8 @@ more than 2800 commits from 195 contributors since release 2.3.
the evaluation cache. This is made possible by the hermetic
evaluation model of flakes.
Intermediate results are not cached.
* The new `--offline` flag disables substituters and causes all
locally cached tarballs and repositories to be considered
up-to-date.

View file

@ -185,7 +185,11 @@ struct EvalSettings : Config
)"};
Setting<bool> useEvalCache{this, true, "eval-cache",
"Whether to use the flake evaluation cache."};
R"(
Whether to use the flake evaluation cache.
Certain commands won't have to evaluate when invoked for the second time with a particular version of a flake.
Intermediate results are not cached.
)"};
Setting<bool> ignoreExceptionsDuringTry{this, false, "ignore-try",
R"(