diff --git a/27d8687144bf38cdaeeb1d81aa72c892b1d0ab88.patch b/27d8687144bf38cdaeeb1d81aa72c892b1d0ab88.patch new file mode 100644 index 0000000000000000000000000000000000000000..95232f8bd1678b265410917b6bb97c74422cfae2 --- /dev/null +++ b/27d8687144bf38cdaeeb1d81aa72c892b1d0ab88.patch @@ -0,0 +1,31 @@ +diff --git a/news/9249.feature.rst b/news/9249.feature.rst +new file mode 100644 +index 0000000000..1c56b39ef5 +--- /dev/null ++++ b/news/9249.feature.rst +@@ -0,0 +1 @@ ++Add a mechanism to delay resolving certain packages, and use it for setuptools. +diff --git a/src/pip/_internal/resolution/resolvelib/provider.py b/src/pip/_internal/resolution/resolvelib/provider.py +index 3883135f12..40a641a2a4 100644 +--- a/src/pip/_internal/resolution/resolvelib/provider.py ++++ b/src/pip/_internal/resolution/resolvelib/provider.py +@@ -117,7 +117,18 @@ def _get_restrictive_rating(requirements): + restrictive = _get_restrictive_rating(req for req, _ in information) + transitive = all(parent is not None for _, parent in information) + key = next(iter(candidates)).name if candidates else "" +- return (restrictive, transitive, key) ++ ++ # HACK: Setuptools have a very long and solid backward compatibility ++ # track record, and extremely few projects would request a narrow, ++ # non-recent version range of it since that would break a lot things. ++ # (Most projects specify it only to request for an installer feature, ++ # which does not work, but that's another topic.) Intentionally ++ # delaying Setuptools helps reduce branches the resolver has to check. ++ # This serves as a temporary fix for issues like "apache-airlfow[all]" ++ # while we work on "proper" branch pruning techniques. ++ delay_this = (key == "setuptools") ++ ++ return (delay_this, restrictive, transitive, key) + + def find_matches(self, requirements): + # type: (Sequence[Requirement]) -> Iterable[Candidate] diff --git a/python-pip.spec b/python-pip.spec index 3d035b59a33f24b5c58f6925acf4d9cb6a79f840..441327da9dcec5787131fb7b38793d21f623830a 100644 --- a/python-pip.spec +++ b/python-pip.spec @@ -6,7 +6,7 @@ pip is the package installer for Python. You can use pip to install packages fro %global bashcompdir %(b=$(pkg-config --variable=completionsdir bash-completion 2>/dev/null); echo ${b:-%{_sysconfdir}/bash_completion.d}) Name: python-%{srcname} Version: 20.2.2 -Release: 3 +Release: 4 Summary: A tool for installing and managing Python packages License: MIT and Python and ASL 2.0 and BSD and ISC and LGPLv2 and MPLv2.0 and (ASL 2.0 or BSD) URL: http://www.pip-installer.org @@ -16,6 +16,7 @@ Patch1: allow-stripping-given-prefix-from-wheel-RECORD-files.patch Patch2: emit-a-warning-when-running-with-root-privileges.patch Patch3: remove-existing-dist-only-if-path-conflicts.patch Patch6000: dummy-certifi.patch +Patch6001: 27d8687144bf38cdaeeb1d81aa72c892b1d0ab88.patch Source10: pip-allow-older-versions.patch %description %{_description} @@ -112,6 +113,9 @@ install -p dist/%{python_wheelname} -t %{buildroot}%{python_wheeldir} %{python_wheeldir}/%{python_wheelname} %changelog +* 20201209205849754911 patch-tracking 20.2.2-4 +- append patch file of upstream repository from <27d8687144bf38cdaeeb1d81aa72c892b1d0ab88> to <27d8687144bf38cdaeeb1d81aa72c892b1d0ab88> + * Wed Nov 4 2020 wangjie -20.2.2-3 - Type:NA - ID:NA @@ -161,4 +165,4 @@ install -p dist/%{python_wheelname} -t %{buildroot}%{python_wheeldir} - DESC: Synchronize a patch * Mon Sep 23 2019 openEuler Buildteam - 18.0-6 -- Package init +- Package init \ No newline at end of file