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

Latest x releases: version sorting broken #1593

Closed
miicha opened this issue Nov 4, 2023 · 3 comments
Closed

Latest x releases: version sorting broken #1593

miicha opened this issue Nov 4, 2023 · 3 comments

Comments

@miicha
Copy link
Contributor

miicha commented Nov 4, 2023

For some packages the version sorting of the x last relases does not work which leads to not fetching any versions.

This is caused by a problem of the version parsing in packaging.version. It usually works but the regex does not match arbitrary letters.
The problem was observed in the pytz package: versions 2004a, 2004b, 2004b.2 are pased correctly but 2004d raises an error.
Additionally the filtering is done in a large try ... except block that silently ignores the error in the on_error function which made debugging necessary.

        elif isinstance(exception, TypeError) or isinstance(exception, ValueError):
            # This occurs for testing or when todolist is corrupt
            pass

The problem could be mitigated by implementing #1433.

@cooperlees
Copy link
Contributor

I don't believe that is PEP440 valid versioning, so due to that I don't expect bandersnatch to support it cleanly.

@miicha
Copy link
Contributor Author

miicha commented Nov 6, 2023

That is very likely. Nevertheless, it is a blocking issue for me to setup a mirror, because there are ~20 required packages that are not downloaded due to this issue (and stay on the todo list). For me the sort_by = time would be sufficient, so feel free to close this entry after merging PR #1594.

@cooperlees
Copy link
Contributor

Won't support outside PEP440 ...

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

2 participants