From d323f33bcadc105798fe43c4c0a5df2ef7630f21 Mon Sep 17 00:00:00 2001 From: Kris Wilson Date: Wed, 30 Nov 2016 13:29:49 -0800 Subject: [PATCH 1/2] Kill zipmanifest monkeypatching. --- pex/pex_bootstrapper.py | 16 ---------------- pex/version.py | 2 +- scripts/coverage.sh | 2 +- 3 files changed, 2 insertions(+), 18 deletions(-) diff --git a/pex/pex_bootstrapper.py b/pex/pex_bootstrapper.py index 137757fab..65a481f31 100644 --- a/pex/pex_bootstrapper.py +++ b/pex/pex_bootstrapper.py @@ -46,20 +46,6 @@ def get_pex_info(entry_point): raise ValueError('Invalid entry_point: %s' % entry_point) -# TODO(wickman) Remove once resolved (#91): -# https://bitbucket.org/pypa/setuptools/issue/154/build_zipmanifest-results-should-be -def monkeypatch_build_zipmanifest(): - import pkg_resources - if not hasattr(pkg_resources, 'build_zipmanifest'): - return - old_build_zipmanifest = pkg_resources.build_zipmanifest - def memoized_build_zipmanifest(archive, memo={}): - if archive not in memo: - memo[archive] = old_build_zipmanifest(archive) - return memo[archive] - pkg_resources.build_zipmanifest = memoized_build_zipmanifest - - def find_in_path(target_interpreter): if os.path.exists(target_interpreter): return target_interpreter @@ -90,7 +76,6 @@ def maybe_reexec_pex(): def bootstrap_pex(entry_point): from .finders import register_finders - monkeypatch_build_zipmanifest() register_finders() maybe_reexec_pex() @@ -104,7 +89,6 @@ def bootstrap_pex_env(entry_point): from .finders import register_finders from .pex_info import PexInfo - monkeypatch_build_zipmanifest() register_finders() PEXEnvironment(entry_point, PexInfo.from_pex(entry_point)).activate() diff --git a/pex/version.py b/pex/version.py index e3ded9f2e..36f3bc06c 100644 --- a/pex/version.py +++ b/pex/version.py @@ -3,5 +3,5 @@ __version__ = '1.1.15' -SETUPTOOLS_REQUIREMENT = 'setuptools>=2.2,<20.11' +SETUPTOOLS_REQUIREMENT = 'setuptools>=5.4.1,<20.11' WHEEL_REQUIREMENT = 'wheel>=0.26.0,<0.30.0' diff --git a/scripts/coverage.sh b/scripts/coverage.sh index 9a58e110f..7253bbc13 100755 --- a/scripts/coverage.sh +++ b/scripts/coverage.sh @@ -4,4 +4,4 @@ coverage run -p -m py.test tests coverage run -p -m pex.bin.pex -v --help >&/dev/null coverage run -p -m pex.bin.pex -v -- scripts/do_nothing.py coverage run -p -m pex.bin.pex -v requests -- scripts/do_nothing.py -coverage run -p -m pex.bin.pex -v . 'setuptools>=2.2,<20' -- scripts/do_nothing.py +coverage run -p -m pex.bin.pex -v . 'setuptools>=5.4.1,<20.11' -- scripts/do_nothing.py From 7503658151d0ac85c059ef6fa29e692ebe5c2f43 Mon Sep 17 00:00:00 2001 From: Kris Wilson Date: Wed, 30 Nov 2016 13:43:54 -0800 Subject: [PATCH 2/2] Bump to setuptools 5.7 --- pex/version.py | 2 +- scripts/coverage.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pex/version.py b/pex/version.py index 36f3bc06c..e0acc849f 100644 --- a/pex/version.py +++ b/pex/version.py @@ -3,5 +3,5 @@ __version__ = '1.1.15' -SETUPTOOLS_REQUIREMENT = 'setuptools>=5.4.1,<20.11' +SETUPTOOLS_REQUIREMENT = 'setuptools>=5.7,<20.11' WHEEL_REQUIREMENT = 'wheel>=0.26.0,<0.30.0' diff --git a/scripts/coverage.sh b/scripts/coverage.sh index 7253bbc13..a7317a8c6 100755 --- a/scripts/coverage.sh +++ b/scripts/coverage.sh @@ -4,4 +4,4 @@ coverage run -p -m py.test tests coverage run -p -m pex.bin.pex -v --help >&/dev/null coverage run -p -m pex.bin.pex -v -- scripts/do_nothing.py coverage run -p -m pex.bin.pex -v requests -- scripts/do_nothing.py -coverage run -p -m pex.bin.pex -v . 'setuptools>=5.4.1,<20.11' -- scripts/do_nothing.py +coverage run -p -m pex.bin.pex -v . 'setuptools>=5.7,<20.11' -- scripts/do_nothing.py