From: Zac Medico Date: Fri, 1 Jun 2007 15:51:36 +0000 (-0000) Subject: Instead of calling sys.exit() when aux_get() fails inside getfetchlist(), convert... X-Git-Tag: v2.2_pre1~1313 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=2f2acc41ca47529dc58d69573988113a0ff2d912;p=portage.git Instead of calling sys.exit() when aux_get() fails inside getfetchlist(), convert the KeyError to an InvalidDependString exception since callers already handle it. svn path=/main/trunk/; revision=6708 --- diff --git a/pym/portage/dbapi/porttree.py b/pym/portage/dbapi/porttree.py index 5488251e6..6130dd49d 100644 --- a/pym/portage/dbapi/porttree.py +++ b/pym/portage/dbapi/porttree.py @@ -362,8 +362,10 @@ class portdbapi(dbapi): try: myuris = self.aux_get(mypkg, ["SRC_URI"], mytree=mytree)[0] except KeyError: - print red("getfetchlist():")+" aux_get() error reading "+mypkg+"; aborting." - sys.exit(1) + # Convert this to an InvalidDependString exception since callers + # already handle it. + raise portage.exception.InvalidDependString( + "getfetchlist(): aux_get() error reading "+mypkg+"; aborting.") if useflags is None: useflags = mysettings["USE"].split()