astral-sh / packse

Python packaging scenarios
Apache License 2.0
93 stars 9 forks source link

Add Exclusive prerelease specifier scenarios #172

Open notatallshaw opened 4 months ago

notatallshaw commented 4 months ago

My first attempt at a PR, let's see how it goes.

This adds two extra scenarios to prerelease specifiers, uv already correctly follows the > exclusive ordered test: https://github.com/astral-sh/uv/issues/2646, but packaging (and therefore pip) does not: https://github.com/pypa/packaging/issues/788

I do not know whether uv implies prerelease from != or not, and I'm not explicitly getting it from the the spec but rather following this comment by the spec author https://github.com/pypa/packaging/issues/776#issuecomment-1900515985, we can wait and see if the explicit test on that check is accepted by packaging in my PR https://github.com/pypa/packaging/pull/794.