aboutsummaryrefslogtreecommitdiffhomepage
path: root/python/google/protobuf/pyext
diff options
context:
space:
mode:
authorGravatar Silviu Calinoiu <silviuc@google.com>2016-02-18 16:12:11 -0800
committerGravatar Silviu Calinoiu <silviuc@google.com>2016-02-18 16:12:11 -0800
commit786f80fe6632902be74f90a577d75e8641494abd (patch)
treec6c2f9a3c5a87cb452bbbb98495d3fa16faec0ff /python/google/protobuf/pyext
parentc003abb40d64ecd6694fab239d3fc126b31eee0d (diff)
Add a modified patch from craigcitro@ to handle namespace sharing.
Diffstat (limited to 'python/google/protobuf/pyext')
-rw-r--r--python/google/protobuf/pyext/__init__.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/python/google/protobuf/pyext/__init__.py b/python/google/protobuf/pyext/__init__.py
index e69de29b..55856141 100644
--- a/python/google/protobuf/pyext/__init__.py
+++ b/python/google/protobuf/pyext/__init__.py
@@ -0,0 +1,4 @@
+try:
+ __import__('pkg_resources').declare_namespace(__name__)
+except ImportError:
+ __path__ = __import__('pkgutil').extend_path(__path__, __name__)