From 8e39ac038b29a358aa1bf9cf4eaeb2987f1eacec Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sun, 1 Sep 2013 17:27:35 -0700 Subject: [PATCH] FakeVartree: infinite _aux_get_wrapper recursion --- pym/_emerge/FakeVartree.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/pym/_emerge/FakeVartree.py b/pym/_emerge/FakeVartree.py index fd87f6c9d..14be50c7f 100644 --- a/pym/_emerge/FakeVartree.py +++ b/pym/_emerge/FakeVartree.py @@ -166,8 +166,13 @@ class FakeVartree(vartree): if self._global_updates is None: self._global_updates = \ grab_global_updates(self._portdb) + + # Bypass _aux_get_wrapper, since calling that + # here would trigger infinite recursion. + aux_keys = Package._dep_keys + self.dbapi._pkg_str_aux_keys + aux_dict = dict(zip(aux_keys, self._aux_get(pkg.cpv, aux_keys))) perform_global_updates( - pkg.cpv, self.dbapi, self._global_updates) + pkg.cpv, aux_dict, self.dbapi, self._global_updates) def dynamic_deps_preload(self, pkg, metadata): if metadata is not None: @@ -300,9 +305,7 @@ def grab_global_updates(portdb): return retupdates -def perform_global_updates(mycpv, mydb, myupdates): - aux_keys = Package._dep_keys + mydb._pkg_str_aux_keys - aux_dict = dict(zip(aux_keys, mydb.aux_get(mycpv, aux_keys))) +def perform_global_updates(mycpv, aux_dict, mydb, myupdates): try: pkg = _pkg_str(mycpv, metadata=aux_dict, settings=mydb.settings) except InvalidData: -- 2.26.2