diff options
| author | Aurelien Bompard <aurelien@bompard.org> | 2011-06-01 09:18:22 +0200 |
|---|---|---|
| committer | Aurelien Bompard <aurelien@bompard.org> | 2011-06-01 09:18:22 +0200 |
| commit | c7470ef715ed90469e7ee8f215d5307834479d8c (patch) | |
| tree | 2c60d22d49976d404e522f2f51752e455f20a23f /pkg_resources.py | |
| parent | 0343339ddae02847a24ef3726eaf1df6789aa4a8 (diff) | |
| download | python-setuptools-git-c7470ef715ed90469e7ee8f215d5307834479d8c.tar.gz | |
Update the child's __path__ in declare_namespace, even if the parent is
already a namespace package -- fixes #204
--HG--
branch : distribute
extra : rebase_source : 48e1ed2309ae053b8987a664231e72c35a0bbb40
Diffstat (limited to 'pkg_resources.py')
| -rw-r--r-- | pkg_resources.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/pkg_resources.py b/pkg_resources.py index 636d6ff9..52d92669 100644 --- a/pkg_resources.py +++ b/pkg_resources.py @@ -1811,10 +1811,10 @@ def declare_namespace(packageName): declare_namespace(parent) if parent not in _namespace_packages: __import__(parent) - try: - path = sys.modules[parent].__path__ - except AttributeError: - raise TypeError("Not a package:", parent) + try: + path = sys.modules[parent].__path__ + except AttributeError: + raise TypeError("Not a package:", parent) # Track what packages are namespaces, so when new path items are added, # they can be updated |
