diff options
author | Zac Medico <zmedico@gentoo.org> | 2009-02-19 02:52:36 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2009-02-19 02:52:36 +0000 |
commit | f522aabc3ddc4a55513c75a39d0b11378ba8f41b (patch) | |
tree | cbbe2a9b592029a6e62931cd0b367777acbaa4a3 /pym/_emerge | |
parent | 0903870129174bb57c0ba33959373eb82f261054 (diff) | |
download | portage-f522aabc3ddc4a55513c75a39d0b11378ba8f41b.tar.gz portage-f522aabc3ddc4a55513c75a39d0b11378ba8f41b.tar.bz2 portage-f522aabc3ddc4a55513c75a39d0b11378ba8f41b.zip |
In python-3.0, the UserDict.DictMixin class has been replaced by
Mapping and MutableMapping from the collections module, but 2to3
doesn't currently account for this change:
http://bugs.python.org/issue2876
As a workaround for the above issue, implement Mapping and
MutableMapping classes as substitutes for UserDict.DictMixin so
that code converted via 2to3 will run.
svn path=/main/trunk/; revision=12628
Diffstat (limited to 'pym/_emerge')
-rw-r--r-- | pym/_emerge/__init__.py | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py index 10b85ea57..00ef6f705 100644 --- a/pym/_emerge/__init__.py +++ b/pym/_emerge/__init__.py @@ -56,7 +56,6 @@ from portage.sets import load_default_config, SETPREFIX from portage.sets.base import InternalPackageSet from itertools import chain, izip -from UserDict import DictMixin try: import cPickle as pickle @@ -4011,7 +4010,7 @@ class Dependency(SlotObject): if self.depth is None: self.depth = 0 -class BlockerCache(DictMixin): +class BlockerCache(portage.cache.mappings.MutableMapping): """This caches blockers of installed packages so that dep_check does not have to be done for every single installed package on every invocation of emerge. The cache is invalidated whenever it is detected that something @@ -4169,11 +4168,6 @@ class BlockerCache(DictMixin): """ return self.BlockerData(*self._cache_data["blockers"][cpv]) - def keys(self): - """This needs to be implemented so that self.__repr__() doesn't raise - an AttributeError.""" - return list(self) - class BlockerDB(object): def __init__(self, root_config): |