| commit | 786f80fe6632902be74f90a577d75e8641494abd | [log] [tgz] |
|---|---|---|
| author | Silviu Calinoiu <silviuc@google.com> | Thu Feb 18 16:12:11 2016 -0800 |
| committer | Silviu Calinoiu <silviuc@google.com> | Thu Feb 18 16:12:11 2016 -0800 |
| tree | c6c2f9a3c5a87cb452bbbb98495d3fa16faec0ff | |
| parent | c003abb40d64ecd6694fab239d3fc126b31eee0d [diff] [blame] |
Add a modified patch from craigcitro@ to handle namespace sharing.
diff --git a/python/google/__init__.py b/python/google/__init__.py index de40ea7..5585614 100755 --- a/python/google/__init__.py +++ b/python/google/__init__.py
@@ -1 +1,4 @@ -__import__('pkg_resources').declare_namespace(__name__) +try: + __import__('pkg_resources').declare_namespace(__name__) +except ImportError: + __path__ = __import__('pkgutil').extend_path(__path__, __name__)