On Fri, Mar 12, 2010 at 08:45:13PM +0100, Filippo Giunchedi wrote: > On Thu, Mar 11, 2010 at 01:29:53PM -0700, John Wright wrote: > > I sent a patch to bug #562257 - any objections to applying and uploading > > this weekend? > > look good, thanks! > just a quick thought: what about testing if the native version parser and > apt_pkg against each other? IOW Version(foo) == AptPkgVersion(foo) and > AptPkgVersion(foo) == Version(foo) must always hold
Good point. I've got another patch ready that makes this work, and makes the test cross-validate version comparison against all combinations of str, NativeVersion, and AptPkgVersion. It also introduces a base class that validates the version against policy section 5.6.12 and handles splitting into epoch, upstream_version, and debian_version components and makes comparison across types a little easier. The meat of the NativeVersion class is the same, so I plan on pushing this and uploading tonight or tomorrow. I'll reply here with the actual patch anyway. -- John Wright <[email protected]> -- http://lists.alioth.debian.org/mailman/listinfo/pkg-python-debian-discuss
