From: Zac Medico Date: Fri, 11 Dec 2009 03:22:40 +0000 (-0000) Subject: Don't use lazy import for portage.cache.mappings because it's imported anyway. X-Git-Tag: v2.2_rc59~29 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=0765de4d004df42a3ebec40b10b1d88155e31911;p=portage.git Don't use lazy import for portage.cache.mappings because it's imported anyway. svn path=/main/trunk/; revision=15029 --- diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py index 3819bfd32..e9c301ed4 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -67,11 +67,16 @@ except ImportError as e: raise try: + + try: + from collections import OrderedDict + except ImportError: + from portage.cache.mappings import OrderedDict + from portage.cache.cache_errors import CacheError import portage.proxy.lazyimport import portage.proxy as proxy proxy.lazyimport.lazyimport(globals(), - 'portage.cache.mappings:OrderedDict', 'portage.checksum', 'portage.checksum:perform_checksum,perform_md5,prelink_capable', 'portage.cvstree', @@ -133,13 +138,6 @@ except ImportError as e: sys.stderr.write(" "+str(e)+"\n\n") raise -try: - from collections import OrderedDict -except ImportError: - # lazy import is above - # from portage.cache.mappings import OrderedDict - pass - if sys.hexversion >= 0x3000000: basestring = str long = int