[Python-ideas] module version number support for semver.org

Nick Coghlan ncoghlan at gmail.com
Tue Apr 15 23:14:20 CEST 2014


On 15 April 2014 16:51, Ryan Hiebert <ryan at ryanhiebert.com> wrote:
> On Tue, Apr 15, 2014 at 3:26 PM, Terry Reedy <tjreedy at udel.edu> wrote:
>>
>> On 4/15/2014 3:25 PM, Andrew Barnert wrote:
>>>
>>>
>>> If my project relies on 2.3.4+ but not 3.x of your project,
>>> and your 2.3.7 breaks backward compatibility, that's a bug in your
>>> project.
>>
>>
>> Agreed. But it means that one cannot use the simplistic algorithm given on
>> the web page: usable = '2.3.4' <= version < '3.0.0'.
>>
> You can if the author releases a 2.3.8 that un-breaks backward
> compatibility. In general, the packaging tools should install the latest
> version that meets all the requirements, so as long as no dependencies
> require the exact broken one to be used, it'll work. Of course, you _could_
> still add that extra guard, it just isn't needed because pip will take care
> of it for you. Denouncement might also still be useful, but in the same
> vein, probably not needed.

For Python, please keep in mind that PEP 440 already covers this in
detail: http://www.python.org/dev/peps/pep-0440/#version-specifiers

It uses the semantic parts of semantic versioning, deals with date
based versioning schemes cleanly, and includes all the flexibility
needed to exclude known broken releases.

The only part of semver that we don't allow is the unorderable
suffixes, and those won't be added because we consider deterministic
ordering to be a requirement.

Regards,
Nick.

>
>
> _______________________________________________
> Python-ideas mailing list
> Python-ideas at python.org
> https://mail.python.org/mailman/listinfo/python-ideas
> Code of Conduct: http://python.org/psf/codeofconduct/



-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia


More information about the Python-ideas mailing list