[Python-Dev] Proposing PEP 345 : Metadata for Python Software Packages 1.2

david.lyon at preisshare.net david.lyon at preisshare.net
Mon Dec 28 05:23:44 CET 2009


> Instead, the default should be ‘==’. That is, ‘Requires-Python: 3’
> should be equivalent to ‘Requires-Python: ==3’; and only “3” or
> “3.0” or
> “3.0.0” etc. will match. I maintain that is what most people will
> expect
> on seeing that syntax.
>
> If a less strict range is desired, the existing comparison operators
> ‘>’, ‘>=’, ‘<’, ‘<=’ are sufficient, more obvious, and
> more explicit. In
> other words, to get the meaning you desire above, the existing operators
> can be used: ‘Requires-Python: >=3, <4’.

Yes,

so that:

  Requires-Python: 1,2,3

means python versions 1,2 or 3.

  Requires-Python: 3

means requires python 3 only. Any version of 3

Whereas:

  Requires-Python: 3.0, 3.1

means only 3.0 and 3.1

  Requires-Python: 2.3, 2.4, 2.5, 2.6

That means, those particular versions.

A user can still try to install on other versions. But
they would get a warning and would do so at their own
risk.

There's no need for extra operator characters as far
as I can see. The comma method proposed originally
seemed to do everything.

David






More information about the Python-Dev mailing list