Closed enikar closed 1 year ago
We only use it to check for the current jedi version (https://github.com/pythonic-emacs/anaconda-mode/blob/160e4e7185881233d96da6722332bd6d038187a9/anaconda-mode.py#L110)
Mainly to check for Python3 compatibility.
I think instead of pulling in packaging
in this bootstrap phase just for that is a bit much. Maybe we can roll our own very simple version.
Doesn't even have to work for all different kind of version string.. just like the
jedi ones e.g. 0.17.2
or 0.18.1
. Maybe a simple ver[4:] > dep[4:] or something is even enough.
Do you want to try and find a solution and create a PR?
Thanks.
well, today I wrote a weak solution. It was a little more complex that what you said. But I don't know how to create a PR… I juste create a patch, at the moment.
Finally, I found how pull requests work.
In Python 3.10 (the version used in debian/sid, for now), distutils is deprecated. PEP 632 recommends to use packaging.version instead of distutils.version.
I suggest to replace the line:
from distutils.version import LooseVersion
byfrom packaging import version
And useversion.parse
instead ofLooseVersion
.Unfortunately, that means to look for
packaging
package which is not in standard python distribution.