Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nimble does not use the nim in the path even if it fulfills the reqs of the current proyect #1256

Closed
AngelEzquerra opened this issue Aug 8, 2024 · 0 comments

Comments

@AngelEzquerra
Copy link

Nimble does not seem to use the nim that is on the path even if it matches the deps of your current project. Because of that, if you have installed nim as a package (even if it is indirectly, e.g. if you nimble install langserver which locks nim at 2.0.2), nimble prioritizes and uses that nim version (2.0.2 in that example) instead of the nim that is on the path.

This is quite confusing and unexpected. What would happen if for excample you later installed some randomlib that locked nim 2.0.0 in its deps, using nimble install randomlib? Would nimble suddently start using nim 2.0.0 instead of 2.0.2 when working on arraymancer which did not use randomlib in any way? Note that the only reason that arraymancer sets nim >= 1.0.0 as a req in its nimble file is so that arraymancer can be used with any version of nim, so it is not feasible to change that references to something newer...

jmgomez added a commit to jmgomez/nimble that referenced this issue Aug 10, 2024
  ## returns the nim directory prioritizing the nimBin one if it satisfais the requirement of the project
  ## otherwise it returns the major version of the nim installed packages that satisfies the requirement of the project (#TODO)
  ## if no nim package satisfies the requirement of the project it returns the nimBin parent directory
  ## only used by the `nimble dump` command which is used to drive the lsp
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

No branches or pull requests

1 participant