From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 2B635138247 for ; Wed, 1 Jan 2014 22:46:46 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 28EFFE09C6; Wed, 1 Jan 2014 22:46:44 +0000 (UTC) Received: from mout.gmx.net (mout.gmx.net [212.227.17.22]) (using TLSv1 with cipher ECDHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 777A5E09BE for ; Wed, 1 Jan 2014 22:46:43 +0000 (UTC) Received: from localhost.localdomain ([213.211.244.136]) by mail.gmx.com (mrgmx001) with ESMTPSA (Nemesis) id 0LhOO8-1VcN9u0P9U-00mZoZ for ; Wed, 01 Jan 2014 23:46:42 +0100 From: SebastianLuther@gmx.de To: gentoo-portage-dev@lists.gentoo.org Subject: [gentoo-portage-dev] [PATCH 1/2] portdbapi.cp_list(): Don't write into xmatch's "match-all" cache Date: Wed, 1 Jan 2014 23:46:26 +0100 Message-Id: <1388616386-28967-1-git-send-email-SebastianLuther@gmx.de> X-Mailer: git-send-email 1.8.3.2 In-Reply-To: <1388614451-18197-1-git-send-email-SebastianLuther@gmx.de> References: <1388614451-18197-1-git-send-email-SebastianLuther@gmx.de> X-Provags-ID: V03:K0:1hlJn+QIhLnuhf3uvRjekp6aFa0SM4FsSLDn3o82rL5KPStFsrY b40mMJ3J/Ck4YeoxZTV/mUkHtqcYLRN5lnomh0xLt7wJDkyAoVLljw4W0YI0uQMtxYvQ43d w7+s2ucIKRu2UV6H6U++VJypOVKbvXCqakNo2lweqUuMouFg3vAw1lRFK5G8+70aGhQ0jlX VsD2OOtZCzolZK12R2qMQ== Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-portage-dev@lists.gentoo.org Reply-to: gentoo-portage-dev@lists.gentoo.org X-Archives-Salt: 35a12378-b2c6-4d5a-8405-be53c58e854a X-Archives-Hash: fb7272d62b25e01ec24db8bfb73a1720 From: Sebastian Luther xmatch returns _pkg_str instances these days. They require metadata access, which cp_list doesn't have. That means that writing cp_list results into the xmatch cache breaks xmatch users that expect _pkg_str instances with full metadata. --- pym/portage/dbapi/porttree.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/pym/portage/dbapi/porttree.py b/pym/portage/dbapi/porttree.py index fc3fc03..53b9648 100644 --- a/pym/portage/dbapi/porttree.py +++ b/pym/portage/dbapi/porttree.py @@ -741,10 +741,6 @@ class portdbapi(dbapi): if self.frozen and mytree is None: cachelist = self.xcache["cp-list"].get(mycp) if cachelist is not None: - # Try to propagate this to the match-all cache here for - # repoman since he uses separate match-all caches for each - # profile (due to differences in _get_implicit_iuse). - self.xcache["match-all"][(mycp, mycp)] = cachelist return cachelist[:] mysplit = mycp.split("/") invalid_category = mysplit[0] not in self._categories @@ -796,7 +792,6 @@ class portdbapi(dbapi): if self.frozen and mytree is None: cachelist = mylist[:] self.xcache["cp-list"][mycp] = cachelist - self.xcache["match-all"][(mycp, mycp)] = cachelist return mylist def freeze(self): -- 1.8.3.2