On Tue, Feb 26, 2013 at 8:17 AM, Nick Coghlan <ncogh...@gmail.com> wrote:
> On Tue, Feb 26, 2013 at 10:08 PM, Michael Foord <fuzzy...@gmail.com> > wrote: > > The current tools are strict with regards to equality - and in dependency > > pinning I would see it as *surprising* that specifying "==1.3" installs > some > > version that isn't precisely 1.3. Having "==" mean approximately-equal, > > instead of the-same-as, seems like a mistake to me. > > The most palatable alternative I've seen so far is for a trailing ".*" > to trigger prefix matching for == and != (it would be disallowed for > anything else). It's *slightly* odd, because the "." is implied rather > than explicit for alphas, betas and release candidates (a choice > driven by the weight of existing practice on PyPI, as well as > CPython's own conventions), but it's probably still a better idea than > trying to change the meaning of "==". > > I *don't* like the idea of (== 1.3) and (== 1.3.0) being equivalent > when (1.3) and (1.3.0) are substantially different, though. Instead, > I'll reinstate a variant of the commentary from PEP 386 that pointed > out the value of always publishing releases with a consistent number > of components by including the trailing ".0". I am still not convinced about the prefix behavior but realize that if we are using sensible consistently three-digit releases then there is no problem. There is an algorithm for splitting "version parts" at either . or the transition from a number to a non-number or vice versa. In pkg_resources 1.1a1 and 1.1.a1 are the same.
_______________________________________________ Distutils-SIG maillist - Distutils-SIG@python.org http://mail.python.org/mailman/listinfo/distutils-sig