-
Notifications
You must be signed in to change notification settings - Fork 87
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
Restricting newest jedi version allowed (and making it possible to configure this requirement) #402
Comments
Code-wise: the responsible lines are If it's to stay more-or-less this way, I'd suggest specyfying both sides, sth like
except the assert is invalid (text comparison doesn't work properly here, one must compare versions numerically, there are various libraries which can do it, I am not sure which one is appropriate here) |
Fix compatibility issues with jedi version 0.18. Require specific version of jedi and service_factory. Fall back to jedi 0.17.2 on python 2. See https://jedi.readthedocs.io/en/latest/docs/changelog.html Fix pythonic-emacs#401 Related pythonic-emacs#402
Patch above solves most important part of the issue, by forcing specific jedi version when one is to be installed. Still, there are two minor issues to consider: a) Patched version switches to strict version (installs b) Patch does not properly fix assert statement, leaving it as
( anaconda-mode/anaconda-mode.el Line 176 in 810163d
The problem is that in case very old jedi (say 0.8.0 ) is installed, this assert will be glad to accept such version without complaints, as alphabetically "0.8.0" >= "0.18.0" ).I am not sure about this part, mayhaps it should be dropped altogether or mayhaps instead of failing anaconda should upgrade to proper version, but if it is to stay, alphabetical comparison is incorrect. Sth like distutils.version.LooseVersion(jedi.__version__) >= distutils.version.LooseVersion(jedi_dep[1]) or mayhaps packaging.version.LegacyVersion , or even simple twoliner
|
Fix compatibility issues with jedi version 0.18. Require specific version of jedi and service_factory. Fall back to jedi 0.17.2 on python 2. See https://jedi.readthedocs.io/en/latest/docs/changelog.html Fix pythonic-emacs#401 Related pythonic-emacs#402
Thanks for you comment. I went with the distutils version as that's the most stable. I'm leaving this ticket open for now as I also think it would be |
Context: everybody who fresh-installed anaconda-mode since December 25h (jedi 0.18.0 release) gets broken installation (see #401 )
At the moment, anaconda-mode installs needed python modules with loose requirement, for example jedi is installed with
jedi>=0.13.0
. Either exact tested version should be specified, or range with two-side restrictions (sayjedi>=0.13.0,<0.18.0
).Preferably, some customizable variable could let one patch this requirement if necessary (
anaconda-jedi-version
…)code-wise it's about constructing
missing_dependencies
variable.The text was updated successfully, but these errors were encountered: