PY-24682 Explicitly remove helpers directory from the sys.path in packaging_tool.py

As a workaround for the pip's issue #4216 and setuptools' #885.
This commit is contained in:
Mikhail Golubev
2017-07-12 17:05:56 +03:00
parent d2648e840b
commit df99eefd48
+8
View File
@@ -161,6 +161,14 @@ def mkdtemp_ifneeded():
def main():
try:
# As a workaround for #885 in setuptools, don't expose other helpers
# in sys.path so as not no confuse it with possible combination of
# namespace/ordinary packages
sys.path.remove(os.path.dirname(__file__))
except ValueError:
pass
retcode = 0
try:
if len(sys.argv) < 2: