summaryrefslogtreecommitdiffstats
path: root/pym/portage/dbapi
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2012-10-17 20:32:20 -0700
committerZac Medico <zmedico@gentoo.org>2012-10-17 20:32:20 -0700
commit5608e26193249acf4d072f7658f88ea7e7222ae4 (patch)
treed3c42bfcb27101364ab8736d2ec00e8dbc54b8bc /pym/portage/dbapi
parentbc63a48af0517b31872141aa06ed1a5f9b6b4f52 (diff)
downloadportage-5608e26193249acf4d072f7658f88ea7e7222ae4.tar.gz
portage-5608e26193249acf4d072f7658f88ea7e7222ae4.tar.bz2
portage-5608e26193249acf4d072f7658f88ea7e7222ae4.zip
bintree/portree: fix getslot for EAPI 5 sub-slot
Diffstat (limited to 'pym/portage/dbapi')
-rw-r--r--pym/portage/dbapi/bintree.py6
-rw-r--r--pym/portage/dbapi/porttree.py6
2 files changed, 4 insertions, 8 deletions
diff --git a/pym/portage/dbapi/bintree.py b/pym/portage/dbapi/bintree.py
index cbcfa728f..f90a4936f 100644
--- a/pym/portage/dbapi/bintree.py
+++ b/pym/portage/dbapi/bintree.py
@@ -1484,9 +1484,7 @@ class binarytree(object):
"Get a slot for a catpkg; assume it exists."
myslot = ""
try:
- myslot = self.dbapi.aux_get(mycatpkg,["SLOT"])[0]
- except SystemExit as e:
- raise
- except Exception as e:
+ myslot = self.dbapi._pkg_str(mycatpkg, None).slot
+ except KeyError:
pass
return myslot
diff --git a/pym/portage/dbapi/porttree.py b/pym/portage/dbapi/porttree.py
index a5945be59..115fc7f29 100644
--- a/pym/portage/dbapi/porttree.py
+++ b/pym/portage/dbapi/porttree.py
@@ -1063,10 +1063,8 @@ class portagetree(object):
"Get a slot for a catpkg; assume it exists."
myslot = ""
try:
- myslot = self.dbapi.aux_get(mycatpkg, ["SLOT"])[0]
- except SystemExit:
- raise
- except Exception:
+ myslot = self.dbapi._pkg_str(mycatpkg, None).slot
+ except KeyError:
pass
return myslot