From a76f5c03136f0c69e8c366bf4069ec8d89d85da7 Mon Sep 17 00:00:00 2001 From: "Jason R. Coombs" Date: Sat, 2 Jan 2016 15:15:47 -0500 Subject: Pop the module off the stack, preventing the 'Version' class from having a different manifestation in packaging than in pkg_resources. --HG-- branch : feature/issue-229 --- setuptools/extern/__init__.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'setuptools/extern') diff --git a/setuptools/extern/__init__.py b/setuptools/extern/__init__.py index 1329285c..e1400238 100644 --- a/setuptools/extern/__init__.py +++ b/setuptools/extern/__init__.py @@ -28,8 +28,7 @@ class VendorImporter: for prefix in self.search_path: try: __import__(prefix + target) - mod = sys.modules[prefix + target] - sys.modules[fullname] = mod + mod = sys.modules[fullname] = sys.modules.pop(prefix + target) return mod except ImportError: pass -- cgit v1.2.1