Open ee7 opened 1 year ago
Try nimble setup after running nimble lock
@Clonkk Thanks. That's what I was missing. It was apparently hard for me to discover.
So I guess it's intended that nimble lock
doesn't automatically do the nimble setup
stuff? If so, someone please close this.
But I'd suggest that we could:
nimble setup
in the nimble lock
section of the nimble docsnimble setup
" to the output of nimble lock
Is this intended?
in general, locking means that you want some particular dependencies and only those dependencies - otherwise, random stuff from random nimble PATH:s can interfere with import
.
That said, seems reasonable that lock should imply setup, though this would be a reasonable issue to raise in https://github.com/nim-lang/nimble/ instead
cc @yyoncho -
Short example
Current output
Expected output
No error. I thought that Nim would just ensure that it uses the package versions from the
nimble.lock
file.Discussion
Is this intended? I am aware of https://github.com/nim-lang/Nim/commit/7c6dcfd968867ec9b2fee5ca3ef8f251a6faa350 and https://github.com/nim-lang/nimble/issues/1004.
Is the intention that after running
nimble lock
:nimble
commands, and nevernim
commands?The same error also breaks e.g.
nimble test
, if you redefine thetest
task for performance like:NIMBLE_DIR
is not set.Nim version
Long example
nimble lock
produces an error if the project is not under version control. So please excuse the boilerplate below - I've tried to make a clear, robust reproduction.So we have the
foo.nimble
file:and the
nimble.lock
file:Current output
Expected output
No error at the end.