Bug #211365 - Use catpkgsplit() instead of pkgsplit() on the cpv in the
authorZac Medico <zmedico@gentoo.org>
Tue, 26 Feb 2008 00:02:53 +0000 (00:02 -0000)
committerZac Medico <zmedico@gentoo.org>
Tue, 26 Feb 2008 00:02:53 +0000 (00:02 -0000)
dblink constructor since otherwise weird categories containing numbers
can make pkgsplit() return None (likely related to version regex handling).
(branches/2.1.2 r9383)

svn path=/main/trunk/; revision=9384

pym/portage/dbapi/vartree.py

index f8a945e9ed4a6ebcee7e1faed4eebcb42ed8f7fa..3c47d24fd18e0fd7e37c71f738bd566f4bdc42da 100644 (file)
@@ -884,7 +884,8 @@ class dblink(object):
                self.cat = cat
                self.pkg = pkg
                self.mycpv = self.cat + "/" + self.pkg
-               self.mysplit = pkgsplit(self.mycpv)
+               self.mysplit = list(catpkgsplit(self.mycpv)[1:])
+               self.mysplit[0] = "%s/%s" % (self.cat, self.mysplit[0])
                self.treetype = treetype
                if vartree is None:
                        from portage import db