<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Sat, Feb 23, 2013 at 10:23 AM, Nick Coghlan <span dir="ltr"><<a href="mailto:ncoghlan@gmail.com" target="_blank">ncoghlan@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="im">On Sun, Feb 24, 2013 at 12:57 AM, Vinay Sajip <<a href="mailto:vinay_sajip@yahoo.co.uk">vinay_sajip@yahoo.co.uk</a>> wrote:<br>

> Nick Coghlan <ncoghlan <at> <a href="http://gmail.com" target="_blank">gmail.com</a>> writes:<br>
><br>
>> Daniel is a fan of this syntax, but I think it is inferior to the<br>
>> implied approach, so don't expect it to survive to any accepted<br>
>> version of the PEP :)<br>
><br>
> Another thing against ~= is that it isn't valid Python syntax. It's not a deal-<br>
> breaker, but it does mean that you can't e.g. use the ast module in the<br>
> implementation. This might be a factor if the mini-language ever grows (as it<br>
> recently did, adding parentheses).<br>
<br>
</div>Daniel persuaded me that the *semantics* of Ruby's ~> pessimistic<br>
version comparison operator are highly desirable. I liked them so<br>
much, I'm now proposing them as the default behaviour of version<br>
specifiers. Thus, the "~=" operator goes away, and you can use "==" to<br>
explicitly request the previously proposed default behaviour, or just<br>
append an extra ".0" if you're more pessimistic about a dependency's<br>
backwards compatibility policies than the default interpretation.<br>
<br>
This and other aspects will be brought up on distutils-sig at some<br>
point not too far in the future :)<br>
<div class="im"><br>
Cheers,<br>
Nick.<br></div></blockquote><div><br></div><div>Join us on distutils-sig! It's like python-dev, except with more distutils! <br></div><div><br></div><div>Good changes, ~> is useful, unlike "starts with". I don't think we should include starts-with at all.</div>
<div><br></div><div>There simply must be a way to spell "equals" that means "equals". It will be used when that so-called security release broke my application that integrates said library in a way that doesn't even expose the flaw.<br>
<br></div><div>Plone depends on hundreds of libraries that probably only use >= or no version at all in their setup.py. Then the buildout.cfg ships with the == versions of all the libraries that the Plone release team actually tested. == is not the common plague that you fear.<br>
</div><div><br></div><div>Requirements specifiers have never been valid Python syntax; note the unquoted version strings. Environment markers are different and do not compare distribution versions.<br><br></div><div>As a aside pkg_resources probably needs an operator [that might be removed when generating PKG-INFO] for use in setup.py install_requires. Setuptools parses distname [OPERATOR version] not distname [OPERATOR? version]<br>
<br></div><div>Daniel<br></div></div></div></div>