From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1QYpoV-0006DV-ID for garchives@archives.gentoo.org; Tue, 21 Jun 2011 01:31:35 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id A5E0D1C020; Tue, 21 Jun 2011 01:31:27 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 7199D1C020 for ; Tue, 21 Jun 2011 01:31:27 +0000 (UTC) Received: from pelican.gentoo.org (unknown [66.219.59.40]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 0619A1B400E for ; Tue, 21 Jun 2011 01:31:27 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id 246008003C for ; Tue, 21 Jun 2011 01:31:26 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: <33b197b02574c0f49d4dce659562d2f3362e5eba.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: pym/portage/package/ebuild/_config/ X-VCS-Repository: proj/portage X-VCS-Files: pym/portage/package/ebuild/_config/UseManager.py X-VCS-Directories: pym/portage/package/ebuild/_config/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: 33b197b02574c0f49d4dce659562d2f3362e5eba Date: Tue, 21 Jun 2011 01:31:26 +0000 (UTC) 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: X-Archives-Hash: 602d88ee881221338da4fa1eeccf8070 commit: 33b197b02574c0f49d4dce659562d2f3362e5eba Author: Zac Medico gentoo org> AuthorDate: Tue Jun 21 01:31:17 2011 +0000 Commit: Zac Medico gentoo org> CommitDate: Tue Jun 21 01:31:17 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/portage.git;a= =3Dcommit;h=3D33b197b0 UseManager: avoid possible repo KeyErrors --- pym/portage/package/ebuild/_config/UseManager.py | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pym/portage/package/ebuild/_config/UseManager.py b/pym/porta= ge/package/ebuild/_config/UseManager.py index de18500..67e9294 100644 --- a/pym/portage/package/ebuild/_config/UseManager.py +++ b/pym/portage/package/ebuild/_config/UseManager.py @@ -148,8 +148,8 @@ class UseManager(object): usemask =3D [] if hasattr(pkg, "repo") and pkg.repo !=3D Package.UNKNOWN_REPO: for repo in [repo.name for repo in self.repositories[pkg.repo].master= s] + [pkg.repo]: - usemask.append(self._repo_usemask_dict[repo]) - cpdict =3D self._repo_pusemask_dict[repo].get(cp) + usemask.append(self._repo_usemask_dict.get(repo, {})) + cpdict =3D self._repo_pusemask_dict.get(repo, {}).get(cp) if cpdict: pkg_usemask =3D ordered_by_atom_specificity(cpdict, pkg) if pkg_usemask: @@ -175,8 +175,8 @@ class UseManager(object): useforce =3D [] if hasattr(pkg, "repo") and pkg.repo !=3D Package.UNKNOWN_REPO: for repo in [repo.name for repo in self.repositories[pkg.repo].master= s] + [pkg.repo]: - useforce.append(self._repo_useforce_dict[repo]) - cpdict =3D self._repo_puseforce_dict[repo].get(cp) + useforce.append(self._repo_useforce_dict.get(repo, {})) + cpdict =3D self._repo_puseforce_dict.get(repo, {}).get(cp) if cpdict: pkg_useforce =3D ordered_by_atom_specificity(cpdict, pkg) if pkg_useforce: