--- pym/_emerge/BlockerDB.py | 4 ++-- pym/_emerge/actions.py | 9 +++------ pym/_emerge/depgraph.py | 8 ++++---- pym/_emerge/resolver/output.py | 4 ++-- pym/_emerge/show_invalid_depstring_notice.py | 4 ++-- 5 files changed, 13 insertions(+), 16 deletions(-)
diff --git a/pym/_emerge/BlockerDB.py b/pym/_emerge/BlockerDB.py index 44a70a098..5b3b01c37 100644 --- a/pym/_emerge/BlockerDB.py +++ b/pym/_emerge/BlockerDB.py @@ -1,4 +1,4 @@ -# Copyright 1999-2015 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 import sys @@ -99,7 +99,7 @@ class BlockerDB(object): trees=dep_check_trees, myroot=new_pkg.root) if not success: # We should never get this far with invalid deps. - show_invalid_depstring_notice(new_pkg, depstr, atoms) + show_invalid_depstring_notice(new_pkg, atoms) assert False blocker_atoms = [atom.lstrip("!") for atom in atoms \ diff --git a/pym/_emerge/actions.py b/pym/_emerge/actions.py index 2293560c1..455aa7e04 100644 --- a/pym/_emerge/actions.py +++ b/pym/_emerge/actions.py @@ -816,8 +816,7 @@ def calc_depclean(settings, trees, ldpath_mtimes, protected_set.add("=" + pkg.cpv) continue except portage.exception.InvalidDependString as e: - show_invalid_depstring_notice(pkg, - pkg._metadata["PROVIDE"], _unicode(e)) + show_invalid_depstring_notice(pkg, _unicode(e)) del e protected_set.add("=" + pkg.cpv) continue @@ -870,8 +869,7 @@ def calc_depclean(settings, trees, ldpath_mtimes, protected_set.add("=" + pkg.cpv) continue except portage.exception.InvalidDependString as e: - show_invalid_depstring_notice(pkg, - pkg._metadata["PROVIDE"], _unicode(e)) + show_invalid_depstring_notice(pkg, _unicode(e)) del e protected_set.add("=" + pkg.cpv) continue @@ -888,8 +886,7 @@ def calc_depclean(settings, trees, ldpath_mtimes, if excluded_set.findAtomForPackage(pkg): required_sets['__excluded__'].add("=" + pkg.cpv) except portage.exception.InvalidDependString as e: - show_invalid_depstring_notice(pkg, - pkg._metadata["PROVIDE"], _unicode(e)) + show_invalid_depstring_notice(pkg, _unicode(e)) del e required_sets['__excluded__'].add("=" + pkg.cpv) diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py index 1c47b4b63..747ef1a1a 100644 --- a/pym/_emerge/depgraph.py +++ b/pym/_emerge/depgraph.py @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 from __future__ import division, print_function, unicode_literals @@ -7095,7 +7095,7 @@ class depgraph(object): # matches (this can happen if an atom lacks a # category). show_invalid_depstring_notice( - pkg, depstr, "%s" % (e,)) + pkg, "%s" % (e,)) del e raise if not success: @@ -7108,7 +7108,7 @@ class depgraph(object): # annoy the user too much (otherwise they'd be # forced to manually unmerge it first). continue - show_invalid_depstring_notice(pkg, depstr, atoms) + show_invalid_depstring_notice(pkg, atoms) return False blocker_atoms = [myatom for myatom in atoms \ if myatom.blocker] @@ -7126,7 +7126,7 @@ class depgraph(object): except portage.exception.InvalidAtom as e: depstr = " ".join(vardb.aux_get(pkg.cpv, dep_keys)) show_invalid_depstring_notice( - pkg, depstr, "Invalid Atom: %s" % (e,)) + pkg, "Invalid Atom: %s" % (e,)) return False for cpv in stale_cache: del blocker_cache[cpv] diff --git a/pym/_emerge/resolver/output.py b/pym/_emerge/resolver/output.py index e993ce17d..24340576c 100644 --- a/pym/_emerge/resolver/output.py +++ b/pym/_emerge/resolver/output.py @@ -1,4 +1,4 @@ -# Copyright 2010-2014 Gentoo Foundation +# Copyright 2010-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 """Resolver output display operation. @@ -316,7 +316,7 @@ class Display(object): depstr, = db.aux_get(pkg.cpv, ["SRC_URI"], myrepo=pkg.repo) show_invalid_depstring_notice( - pkg, depstr, _unicode(e)) + pkg, _unicode(e)) raise except SignatureException: # missing/invalid binary package SIZE signature diff --git a/pym/_emerge/show_invalid_depstring_notice.py b/pym/_emerge/show_invalid_depstring_notice.py index a230b3152..e11ea65ed 100644 --- a/pym/_emerge/show_invalid_depstring_notice.py +++ b/pym/_emerge/show_invalid_depstring_notice.py @@ -1,4 +1,4 @@ -# Copyright 1999-2010 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 import logging @@ -7,7 +7,7 @@ import portage from portage import os from portage.util import writemsg_level -def show_invalid_depstring_notice(parent_node, depstring, error_msg): +def show_invalid_depstring_notice(parent_node, error_msg): msg1 = "\n\n!!! Invalid or corrupt dependency specification: " + \ "\n\n%s\n\n%s\n\n" % (error_msg, parent_node) -- 2.16.2