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

Using packaging version <22 starts to conflict with other dependencies #15898

Closed
fabianegli opened this issue Apr 5, 2023 · 4 comments · Fixed by #16058
Closed

Using packaging version <22 starts to conflict with other dependencies #15898

fabianegli opened this issue Apr 5, 2023 · 4 comments · Fixed by #16058

Comments

@fabianegli
Copy link

fabianegli commented Apr 5, 2023

The world moves on and packaging <22 as defined in the pyproject.toml dependencies starts being incompatible with some of the packages that might be used in concert with galaxy tool util. The reason why it was restricted is that LegacyVersion was dropped in packaging 22 and is used here to parse package versions which are not SemVer versions. However, there might be a path to resolve this issue by using packaging.version.parse instead as already mentioned in

Right ... where possible we should probably use https://packaging.pypa.io/en/latest/version/#packaging.version.parse to construct the version.

IIRC that would allow alpha, beta and similar suffixes to sort lower than the release version.

Originally posted by @mvdbeek in #5408 (comment)

@fabianegli
Copy link
Author

Alternatively, You could just distribute the code for LegacyVersion, as it is licensed under MIT as well. For reference: pypa/packaging#530 (comment)

@mvdbeek
Copy link
Member

mvdbeek commented Apr 5, 2023

Originally posted by @mvdbeek in #5408 (comment)

we've been doing that for years and of course that doesn't help with LegacyVersion being dropped.

the second suggestion seems fine, can you open a PR ? you'd probably also need to wrap parse_verison

@nsoranzo
Copy link
Member

nsoranzo commented Apr 5, 2023

See also #13570 .

@fabianegli
Copy link
Author

I am not currently in a position to work on this, if anyone else feels like it, please feel free to have at it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants