From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([69.77.167.62] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1KBw9A-00068s-58 for garchives@archives.gentoo.org; Thu, 26 Jun 2008 18:24:40 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 771CAE04B5; Thu, 26 Jun 2008 18:24:39 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 55249E04B5 for ; Thu, 26 Jun 2008 18:24:39 +0000 (UTC) Received: from stork.gentoo.org (stork.gentoo.org [64.127.104.133]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTP id EB388679B9 for ; Thu, 26 Jun 2008 18:24:38 +0000 (UTC) Received: from zmedico by stork.gentoo.org with local (Exim 4.69) (envelope-from ) id 1KBw94-0008KS-TT for gentoo-commits@lists.gentoo.org; Thu, 26 Jun 2008 18:24:34 +0000 To: gentoo-commits@lists.gentoo.org From: "Zac Medico (zmedico)" Subject: [gentoo-commits] portage r10802 - main/trunk/pym/portage/dbapi X-VCS-Repository: portage X-VCS-Revision: 10802 X-VCS-Files: main/trunk/pym/portage/dbapi/__init__.py X-VCS-Directories: main/trunk/pym/portage/dbapi X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico Content-Type: text/plain; charset=UTF-8 Message-Id: Sender: Zac Medico Date: Thu, 26 Jun 2008 18:24:34 +0000 Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: 399e0138-030f-411f-a121-4ae107e7c76d X-Archives-Hash: 9e480e8079babce85d59d2f1b23683f2 Author: zmedico Date: 2008-06-26 18:24:34 +0000 (Thu, 26 Jun 2008) New Revision: 10802 Modified: main/trunk/pym/portage/dbapi/__init__.py Log: Handle KeyError from aux_get() inside dbapi._iter_match_slot() and _iter_match_use(). Thanks to grobian for reporting. Modified: main/trunk/pym/portage/dbapi/__init__.py =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- main/trunk/pym/portage/dbapi/__init__.py 2008-06-26 17:11:52 UTC (rev= 10801) +++ main/trunk/pym/portage/dbapi/__init__.py 2008-06-26 18:24:34 UTC (rev= 10802) @@ -135,8 +135,11 @@ =20 def _iter_match_slot(self, atom, cpv_iter): for cpv in cpv_iter: - if self.aux_get(cpv, ["SLOT"])[0] =3D=3D atom.slot: - yield cpv + try: + if self.aux_get(cpv, ["SLOT"])[0] =3D=3D atom.slot: + yield cpv + except KeyError: + continue =20 def _iter_match_use(self, atom, cpv_iter): """ @@ -146,7 +149,10 @@ if self._iuse_implicit is None: self._iuse_implicit =3D self.settings._get_implicit_iuse() for cpv in cpv_iter: - iuse, use =3D self.aux_get(cpv, ["IUSE", "USE"]) + try: + iuse, use =3D self.aux_get(cpv, ["IUSE", "USE"]) + except KeyError: + continue use =3D use.split() iuse =3D self._iuse_implicit.union( re.escape(x.lstrip("+-")) for x in iuse.split()) --=20 gentoo-commits@lists.gentoo.org mailing list