From 56afd7d903dda12d1ce0750916c48523e8992494 Mon Sep 17 00:00:00 2001 From: openeuler-ci-bot <80474298@qq.com> Date: Tue, 29 Dec 2020 17:58:53 +0800 Subject: [PATCH 1/2] [patch tracking] 20201229175849755199 - https://github.com/pypa/pip/commit/af5b7fe1f903faa1309e88e67e1e91b0ccfd68b1 --- ...7fe1f903faa1309e88e67e1e91b0ccfd68b1.patch | 88 +++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 af5b7fe1f903faa1309e88e67e1e91b0ccfd68b1.patch diff --git a/af5b7fe1f903faa1309e88e67e1e91b0ccfd68b1.patch b/af5b7fe1f903faa1309e88e67e1e91b0ccfd68b1.patch new file mode 100644 index 0000000..e0b9f21 --- /dev/null +++ b/af5b7fe1f903faa1309e88e67e1e91b0ccfd68b1.patch @@ -0,0 +1,88 @@ +diff --git a/news/8a225e3d-998e-4924-92e6-2ab2173159f8.trivial.rst b/news/8a225e3d-998e-4924-92e6-2ab2173159f8.trivial.rst +new file mode 100644 +index 0000000000..e69de29bb2 +diff --git a/src/pip/__main__.py b/src/pip/__main__.py +index ea738bfc24..1005489f32 100644 +--- a/src/pip/__main__.py ++++ b/src/pip/__main__.py +@@ -18,7 +18,7 @@ + path = os.path.dirname(os.path.dirname(__file__)) + sys.path.insert(0, path) + +-from pip._internal.cli.main import main as _main # isort:skip # noqa ++from pip._internal.cli.main import main as _main + + if __name__ == '__main__': + sys.exit(_main()) +diff --git a/src/pip/_internal/network/auth.py b/src/pip/_internal/network/auth.py +index a63a2965c6..174eb83487 100644 +--- a/src/pip/_internal/network/auth.py ++++ b/src/pip/_internal/network/auth.py +@@ -31,7 +31,7 @@ + logger = logging.getLogger(__name__) + + try: +- import keyring # noqa ++ import keyring + except ImportError: + keyring = None + except Exception as exc: +diff --git a/src/pip/_internal/req/req_set.py b/src/pip/_internal/req/req_set.py +index 96bb4013eb..fa58be6634 100644 +--- a/src/pip/_internal/req/req_set.py ++++ b/src/pip/_internal/req/req_set.py +@@ -24,7 +24,7 @@ def __init__(self, check_supported_wheels=True): + """Create a RequirementSet. + """ + +- self.requirements = OrderedDict() # type: Dict[str, InstallRequirement] # noqa: E501 ++ self.requirements = OrderedDict() # type: Dict[str, InstallRequirement] + self.check_supported_wheels = check_supported_wheels + + self.unnamed_requirements = [] # type: List[InstallRequirement] +@@ -69,7 +69,7 @@ def add_requirement( + parent_req_name=None, # type: Optional[str] + extras_requested=None # type: Optional[Iterable[str]] + ): +- # type: (...) -> Tuple[List[InstallRequirement], Optional[InstallRequirement]] # noqa: E501 ++ # type: (...) -> Tuple[List[InstallRequirement], Optional[InstallRequirement]] + """Add install_req as a requirement to install. + + :param parent_req_name: The name of the requirement that needed this +diff --git a/src/pip/_internal/utils/logging.py b/src/pip/_internal/utils/logging.py +index 6e1aff1238..687bfe3b2f 100644 +--- a/src/pip/_internal/utils/logging.py ++++ b/src/pip/_internal/utils/logging.py +@@ -45,7 +45,7 @@ class BrokenStdoutLoggingError(Exception): + # https://bugs.python.org/issue30418 + def _is_broken_pipe_error(exc_class, exc): + """See the docstring for non-Windows below.""" +- return ((exc_class is BrokenPipeError) or # noqa: F821 ++ return ((exc_class is BrokenPipeError) or + (exc_class is OSError and + exc.errno in (errno.EINVAL, errno.EPIPE))) + else: +@@ -58,7 +58,7 @@ def _is_broken_pipe_error(exc_class, exc): + exc_class: an exception class. + exc: an exception instance. + """ +- return (exc_class is BrokenPipeError) # noqa: F821 ++ return (exc_class is BrokenPipeError) + + + @contextlib.contextmanager +diff --git a/src/pip/_internal/utils/misc.py b/src/pip/_internal/utils/misc.py +index bd205ada5d..85e26a0214 100644 +--- a/src/pip/_internal/utils/misc.py ++++ b/src/pip/_internal/utils/misc.py +@@ -170,9 +170,7 @@ def path_to_display(path): + except UnicodeDecodeError: + # Include the full bytes to make troubleshooting easier, even though + # it may not be very human readable. +- # Silence the "F821 undefined name 'ascii'" flake8 error since +- # ascii() is a built-in. +- display_path = ascii(path) # noqa: F821 ++ display_path = ascii(path) + + return display_path + -- Gitee From 81a3b539ff7e7f432f8f04b74254009d15bf20dd Mon Sep 17 00:00:00 2001 From: openeuler-ci-bot <80474298@qq.com> Date: Tue, 29 Dec 2020 17:58:54 +0800 Subject: [PATCH 2/2] [patch tracking] 20201229175849755199 - update spec file --- python-pip.spec | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/python-pip.spec b/python-pip.spec index 3d035b5..e997981 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: af5b7fe1f903faa1309e88e67e1e91b0ccfd68b1.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 +* 20201229175849755199 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 -- Gitee