aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2021-01-17 00:47:13 -0800
committerZac Medico <zmedico@gentoo.org>2021-01-17 00:47:26 -0800
commitbdc75b3aa217649f6d835b04eb3cac879459c0a0 (patch)
tree83c1dd8577eea695e8de20d1eba6ece0b6171b2c
parentvardbapi.move_ent: remove redundant self._pkg_str calls (diff)
downloadportage-bdc75b3aa217649f6d835b04eb3cac879459c0a0.tar.gz
portage-bdc75b3aa217649f6d835b04eb3cac879459c0a0.tar.bz2
portage-bdc75b3aa217649f6d835b04eb3cac879459c0a0.zip
bindbapi.move_ent: remove redundant self._pkg_str calls
Signed-off-by: Zac Medico <zmedico@gentoo.org>
-rw-r--r--lib/portage/dbapi/bintree.py10
1 files changed, 3 insertions, 7 deletions
diff --git a/lib/portage/dbapi/bintree.py b/lib/portage/dbapi/bintree.py
index 7e24589e5..528a68979 100644
--- a/lib/portage/dbapi/bintree.py
+++ b/lib/portage/dbapi/bintree.py
@@ -1,4 +1,4 @@
-# Copyright 1998-2020 Gentoo Authors
+# Copyright 1998-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
__all__ = ["bindbapi", "binarytree"]
@@ -27,7 +27,7 @@ from portage.cache.mappings import slot_dict_class
from portage.const import BINREPOS_CONF_FILE, CACHE_PATH, SUPPORTED_XPAK_EXTENSIONS
from portage.dbapi.virtual import fakedbapi
from portage.dep import Atom, use_reduce, paren_enclose
-from portage.exception import AlarmSignal, InvalidData, InvalidPackageName, \
+from portage.exception import AlarmSignal, InvalidPackageName, \
ParseError, PortageException
from portage.localization import _
from portage.package.ebuild.profile_iuse import iter_iuse_vars
@@ -466,11 +466,7 @@ class binarytree:
if not origmatches:
return moves
for mycpv in origmatches:
- try:
- mycpv = self.dbapi._pkg_str(mycpv, None)
- except (KeyError, InvalidData):
- continue
- mycpv_cp = portage.cpv_getkey(mycpv)
+ mycpv_cp = mycpv.cp
if mycpv_cp != origcp:
# Ignore PROVIDE virtual match.
continue