Nix run download cache

The command nix run <some remote flake> seems not to download the remote flake on every invocation.

Is this correct?

If so, it’s reasonable, but very annoying if there is a bug on the remote flake, you fix the bug, and want to test it at a location which has cached the buggy version. (This throws a big spanner in the works of the stateless, declarative and reproducible ideal!) How can this cache be invalidated?

If the remote flake is github or gitlab schema, it might be affected by the tarball cache. --tarball-ttl 0 should help

The default is 3600 (1h).

1 Like

The one that was causing me grief right now, happens to be git+https, but your suggestion appears to have worked.

Any ideas how to work around

warning: ignoring the user-specified setting 'tarball-ttl', because it is a restricted setting and you are not a trusted user