diff --git a/be9637f7f57d1d6e97dfbdd2bdc698edbba73d9f.patch b/be9637f7f57d1d6e97dfbdd2bdc698edbba73d9f.patch new file mode 100644 index 0000000000000000000000000000000000000000..6e767494761d38c141682bbc4632a2f23da88fd0 --- /dev/null +++ b/be9637f7f57d1d6e97dfbdd2bdc698edbba73d9f.patch @@ -0,0 +1,352 @@ +diff --git a/.azure-pipelines/jobs/test-windows.yml b/.azure-pipelines/jobs/test-windows.yml +index 6053b0eb00..99cd8a836b 100644 +--- a/.azure-pipelines/jobs/test-windows.yml ++++ b/.azure-pipelines/jobs/test-windows.yml +@@ -9,14 +9,8 @@ jobs: + vmImage: ${{ parameters.vmImage }} + strategy: + matrix: +- "2.7-x86": +- python.version: '2.7' +- python.architecture: x86 +- "2.7": # because Python 2! +- python.version: '2.7' +- python.architecture: x64 +- "3.5": # lowest Py3 version +- python.version: '3.5' ++ "3.6": # lowest Python version ++ python.version: '3.6' + python.architecture: x64 + "3.8": # current + python.version: '3.8' +@@ -38,16 +32,10 @@ jobs: + vmImage: ${{ parameters.vmImage }} + strategy: + matrix: +- "3.6": +- python.version: '3.6' +- python.architecture: x64 + "3.7": + python.version: '3.7' + python.architecture: x64 + # This is for Windows, so test x86 builds +- "3.5-x86": +- python.version: '3.5' +- python.architecture: x86 + "3.6-x86": + python.version: '3.6' + python.architecture: x86 +diff --git a/.azure-pipelines/jobs/test.yml b/.azure-pipelines/jobs/test.yml +index 274e075a69..a3a0ef80b6 100644 +--- a/.azure-pipelines/jobs/test.yml ++++ b/.azure-pipelines/jobs/test.yml +@@ -9,8 +9,8 @@ jobs: + vmImage: ${{ parameters.vmImage }} + strategy: + matrix: +- "2.7": +- python.version: '2.7' ++ "3.6": # lowest Python version ++ python.version: '3.6' + python.architecture: x64 + "3.8": + python.version: '3.8' +@@ -29,12 +29,6 @@ jobs: + vmImage: ${{ parameters.vmImage }} + strategy: + matrix: +- "3.5": +- python.version: '3.5' +- python.architecture: x64 +- "3.6": +- python.version: '3.6' +- python.architecture: x64 + "3.7": + python.version: '3.7' + python.architecture: x64 +diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml +index 5d7b9acab8..c7afa8d35e 100644 +--- a/.github/workflows/macos.yml ++++ b/.github/workflows/macos.yml +@@ -91,7 +91,7 @@ jobs: + strategy: + fail-fast: false + matrix: +- python: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9] ++ python: [3.6, 3.7, 3.8, 3.9] + + steps: + # Caches +diff --git a/.travis.yml b/.travis.yml +index 165d2ef154..6610b6eb01 100644 +--- a/.travis.yml ++++ b/.travis.yml +@@ -23,13 +23,9 @@ jobs: + # PyPy + - stage: secondary + env: GROUP=1 +- python: pypy3.5-7.0.0 ++ python: pypy3.6-7.3.1 + - env: GROUP=2 +- python: pypy3.5-7.0.0 +- - env: GROUP=1 +- python: pypy2.7-7.1.1 +- - env: GROUP=2 +- python: pypy2.7-7.1.1 ++ python: pypy3.6-7.3.1 + + before_install: tools/travis/setup.sh + install: travis_retry tools/travis/install.sh +diff --git a/docs/html/development/ci.rst b/docs/html/development/ci.rst +index 5befb316a4..5c33231b1b 100644 +--- a/docs/html/development/ci.rst ++++ b/docs/html/development/ci.rst +@@ -17,12 +17,9 @@ Supported interpreters + + pip support a variety of Python interpreters: + +-- CPython 2.7 +-- CPython 3.5 + - CPython 3.6 + - CPython 3.7 + - CPython 3.8 +-- Latest PyPy + - Latest PyPy3 + + on different operating systems: +@@ -95,9 +92,6 @@ Actual testing + +------------------------------+---------------+-----------------+ + | **interpreter** | **unit** | **integration** | + +-----------+----------+-------+---------------+-----------------+ +-| | | CP2.7 | Azure | Azure | +-| | +-------+---------------+-----------------+ +-| | | CP3.5 | Azure | | + | | +-------+---------------+-----------------+ + | | | CP3.6 | Azure | | + | | +-------+---------------+-----------------+ +@@ -105,77 +99,45 @@ Actual testing + | | +-------+---------------+-----------------+ + | | | CP3.8 | Azure | | + | | +-------+---------------+-----------------+ +-| | | PyPy | | | +-| | +-------+---------------+-----------------+ + | | | PyPy3 | | | + | Windows +----------+-------+---------------+-----------------+ +-| | | CP2.7 | Azure | Azure | +-| | +-------+---------------+-----------------+ +-| | | CP3.5 | Azure | Azure | +-| | +-------+---------------+-----------------+ + | | | CP3.6 | Azure | | + | | +-------+---------------+-----------------+ + | | x64 | CP3.7 | Azure | | + | | +-------+---------------+-----------------+ + | | | CP3.8 | Azure | Azure | + | | +-------+---------------+-----------------+ +-| | | PyPy | | | +-| | +-------+---------------+-----------------+ + | | | PyPy3 | | | + +-----------+----------+-------+---------------+-----------------+ +-| | | CP2.7 | | | +-| | +-------+---------------+-----------------+ +-| | | CP3.5 | | | +-| | +-------+---------------+-----------------+ + | | | CP3.6 | | | + | | +-------+---------------+-----------------+ + | | x86 | CP3.7 | | | + | | +-------+---------------+-----------------+ + | | | CP3.8 | | | + | | +-------+---------------+-----------------+ +-| | | PyPy | | | +-| | +-------+---------------+-----------------+ + | | | PyPy3 | | | + | Linux +----------+-------+---------------+-----------------+ +-| | | CP2.7 | Azure | Azure | +-| | +-------+---------------+-----------------+ +-| | | CP3.5 | Azure | Azure | +-| | +-------+---------------+-----------------+ + | | | CP3.6 | Azure | Azure | + | | +-------+---------------+-----------------+ + | | x64 | CP3.7 | Azure | Azure | + | | +-------+---------------+-----------------+ + | | | CP3.8 | Azure | Azure | + | | +-------+---------------+-----------------+ +-| | | PyPy | Travis | Travis | +-| | +-------+---------------+-----------------+ + | | | PyPy3 | Travis | Travis | + +-----------+----------+-------+---------------+-----------------+ +-| | | CP2.7 | | | +-| | +-------+---------------+-----------------+ +-| | | CP3.5 | | | +-| | +-------+---------------+-----------------+ + | | | CP3.6 | | | + | | +-------+---------------+-----------------+ + | | x86 | CP3.7 | | | + | | +-------+---------------+-----------------+ + | | | CP3.8 | | | + | | +-------+---------------+-----------------+ +-| | | PyPy | | | +-| | +-------+---------------+-----------------+ + | | | PyPy3 | | | + | MacOS +----------+-------+---------------+-----------------+ +-| | | CP2.7 | Azure | Azure | +-| | +-------+---------------+-----------------+ +-| | | CP3.5 | Azure | Azure | +-| | +-------+---------------+-----------------+ + | | | CP3.6 | Azure | Azure | + | | +-------+---------------+-----------------+ + | | x64 | CP3.7 | Azure | Azure | + | | +-------+---------------+-----------------+ + | | | CP3.8 | Azure | Azure | + | | +-------+---------------+-----------------+ +-| | | PyPy | | | +-| | +-------+---------------+-----------------+ + | | | PyPy3 | | | + +-----------+----------+-------+---------------+-----------------+ +diff --git a/docs/html/development/release-process.rst b/docs/html/development/release-process.rst +index 91ce3e2337..17d11e7d1c 100644 +--- a/docs/html/development/release-process.rst ++++ b/docs/html/development/release-process.rst +@@ -70,16 +70,9 @@ their merits. + Python 2 Support + ---------------- + +-pip will continue to ensure that it runs on Python 2.7 after the `CPython 2.7 +-EOL date`_. Support for Python 2.7 will be dropped, if bugs in Python 2.7 itself +-make this necessary (which is unlikely) or in pip 21.0 (Jan 2021), whichever is +-earlier. +- +-However, bugs reported with pip which only occur on Python 2.7 would likely not +-be addressed directly by pip's maintainers. Pull Requests to fix Python 2.7 +-only bugs will be considered, and merged (subject to normal review processes). +-Note that there may be delays due to the lack of developer resources for +-reviewing such pull requests. ++pip 20.3 was the last version of pip that supported Python 2. Bugs reported ++with pip which only occur on Python 2.7 will likely be closed as "won't fix" ++issues by pip's maintainers. + + Python Support Policy + --------------------- +diff --git a/docs/html/installing.rst b/docs/html/installing.rst +index a49aebea4a..9e2c7051ef 100644 +--- a/docs/html/installing.rst ++++ b/docs/html/installing.rst +@@ -206,7 +206,7 @@ Upgrading pip + Python and OS Compatibility + =========================== + +-pip works with CPython versions 2.7, 3.5, 3.6, 3.7, 3.8 and also PyPy. ++pip works with CPython versions 3.6, 3.7, 3.8 and also PyPy. + + This means pip works on the latest patch version of each of these minor + versions. Previous patch versions are supported on a best effort approach. +diff --git a/news/6148.removal.rst b/news/6148.removal.rst +new file mode 100644 +index 0000000000..cf6d85e70b +--- /dev/null ++++ b/news/6148.removal.rst +@@ -0,0 +1 @@ ++Drop support for Python 2. +diff --git a/news/9189.removal.rst b/news/9189.removal.rst +new file mode 100644 +index 0000000000..79928cbb15 +--- /dev/null ++++ b/news/9189.removal.rst +@@ -0,0 +1 @@ ++Drop support for Python 3.5. +diff --git a/noxfile.py b/noxfile.py +index 29e3959e46..b94cfe86fe 100644 +--- a/noxfile.py ++++ b/noxfile.py +@@ -70,7 +70,7 @@ def should_update_common_wheels(): + # completely to nox for all our automation. Contributors should prefer using + # `tox -e ...` until this note is removed. + # ----------------------------------------------------------------------------- +-@nox.session(python=["2.7", "3.5", "3.6", "3.7", "3.8", "3.9", "pypy", "pypy3"]) ++@nox.session(python=["3.6", "3.7", "3.8", "3.9", "pypy3"]) + def test(session): + # Get the common wheels. + if should_update_common_wheels(): +diff --git a/setup.py b/setup.py +index 2601d8bd91..b7d0e8f51d 100644 +--- a/setup.py ++++ b/setup.py +@@ -40,10 +40,8 @@ def get_version(rel_path): + "License :: OSI Approved :: MIT License", + "Topic :: Software Development :: Build Tools", + "Programming Language :: Python", +- "Programming Language :: Python :: 2", +- "Programming Language :: Python :: 2.7", + "Programming Language :: Python :: 3", +- "Programming Language :: Python :: 3.5", ++ "Programming Language :: Python :: 3 :: Only" + "Programming Language :: Python :: 3.6", + "Programming Language :: Python :: 3.7", + "Programming Language :: Python :: 3.8", +@@ -85,5 +83,5 @@ def get_version(rel_path): + }, + + zip_safe=False, +- python_requires='>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*', ++ python_requires='>=3.6', + ) +diff --git a/src/pip/_internal/cli/base_command.py b/src/pip/_internal/cli/base_command.py +index 7f05efb85d..ce93552b3c 100644 +--- a/src/pip/_internal/cli/base_command.py ++++ b/src/pip/_internal/cli/base_command.py +@@ -6,7 +6,6 @@ + import logging.config + import optparse + import os +-import platform + import sys + import traceback + +@@ -139,35 +138,6 @@ def _main(self, args): + user_log_file=options.log, + ) + +- if ( +- sys.version_info[:2] == (2, 7) and +- not options.no_python_version_warning +- ): +- message = ( +- "pip 21.0 will drop support for Python 2.7 in January 2021. " +- "More details about Python 2 support in pip can be found at " +- "https://pip.pypa.io/en/latest/development/release-process/#python-2-support" # noqa +- ) +- if platform.python_implementation() == "CPython": +- message = ( +- "Python 2.7 reached the end of its life on January " +- "1st, 2020. Please upgrade your Python as Python 2.7 " +- "is no longer maintained. " +- ) + message +- deprecated(message, replacement=None, gone_in="21.0") +- +- if ( +- sys.version_info[:2] == (3, 5) and +- not options.no_python_version_warning +- ): +- message = ( +- "Python 3.5 reached the end of its life on September " +- "13th, 2020. Please upgrade your Python as Python 3.5 " +- "is no longer maintained. pip 21.0 will drop support " +- "for Python 3.5 in January 2021." +- ) +- deprecated(message, replacement=None, gone_in="21.0") +- + # TODO: Try to get these passing down from the command? + # without resorting to os.environ to hold these. + # This also affects isolated builds and it should. +diff --git a/tests/conftest.py b/tests/conftest.py +index dc1fdb5140..78be52788a 100644 +--- a/tests/conftest.py ++++ b/tests/conftest.py +@@ -496,7 +496,7 @@ def in_memory_pip(): + @pytest.fixture(scope="session") + def deprecated_python(): + """Used to indicate whether pip deprecated this Python version""" +- return sys.version_info[:2] in [(2, 7), (3, 5)] ++ return sys.version_info[:2] in [] + + + @pytest.fixture(scope="session") diff --git a/python-pip.spec b/python-pip.spec index 3d035b59a33f24b5c58f6925acf4d9cb6a79f840..eec3fbbd10312a7d0205efcab0c85350724f4b06 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: be9637f7f57d1d6e97dfbdd2bdc698edbba73d9f.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 +* 20201221025849753945 patch-tracking 20.2.2-4 +- append patch file of upstream repository from to + * 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