Update to 19.2.3 (#1742230)
This commit is contained in:
parent
a0ac853b8c
commit
add791f1d5
2
.gitignore
vendored
2
.gitignore
vendored
@ -36,3 +36,5 @@ pip-0.7.2.tar.gz
|
||||
/pip-19.1-tests.tar.gz
|
||||
/pip-19.1.1.tar.gz
|
||||
/pip-19.1.1-tests.tar.gz
|
||||
/pip-19.2.3.tar.gz
|
||||
/pip-19.2.3-tests.tar.gz
|
||||
|
22
6788.patch
Normal file
22
6788.patch
Normal file
@ -0,0 +1,22 @@
|
||||
From bbbbe07aab24ebaec228624cf6d0100ebe58b00a Mon Sep 17 00:00:00 2001
|
||||
From: Hugo <hugovk@users.noreply.github.com>
|
||||
Date: Thu, 25 Jul 2019 10:47:05 +0300
|
||||
Subject: [PATCH] Consistently get version string, ignoring alpha/beta
|
||||
|
||||
---
|
||||
tests/functional/test_install.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/tests/functional/test_install.py b/tests/functional/test_install.py
|
||||
index 96b780f3c..9481cfd08 100644
|
||||
--- a/tests/functional/test_install.py
|
||||
+++ b/tests/functional/test_install.py
|
||||
@@ -1306,7 +1306,7 @@ def test_double_install_fail(script):
|
||||
def _get_expected_error_text():
|
||||
return (
|
||||
"Package 'pkga' requires a different Python: {} not in '<1.0'"
|
||||
- ).format(sys.version.split()[0])
|
||||
+ ).format('.'.join(map(str, sys.version_info[:3])))
|
||||
|
||||
|
||||
def test_install_incompatible_python_requires(script):
|
@ -1,110 +0,0 @@
|
||||
diff --git a/src/pip/_internal/commands/install.py b/src/pip/_internal/commands/install.py
|
||||
index 1c244d23..4b07ec0f 100644
|
||||
--- a/src/pip/_internal/commands/install.py
|
||||
+++ b/src/pip/_internal/commands/install.py
|
||||
@@ -109,6 +109,14 @@ class InstallCommand(RequirementCommand):
|
||||
default=None,
|
||||
help="Installation prefix where lib, bin and other top-level "
|
||||
"folders are placed")
|
||||
+ cmd_opts.add_option(
|
||||
+ '--strip-file-prefix',
|
||||
+ dest='strip_file_prefix',
|
||||
+ metavar='prefix',
|
||||
+ default=None,
|
||||
+ help="Strip given prefix from script paths in wheel RECORD."
|
||||
+ )
|
||||
+
|
||||
|
||||
cmd_opts.add_option(cmdoptions.build_dir())
|
||||
|
||||
@@ -391,6 +399,7 @@ class InstallCommand(RequirementCommand):
|
||||
pycompile=options.compile,
|
||||
warn_script_location=warn_script_location,
|
||||
use_user_site=options.use_user_site,
|
||||
+ strip_file_prefix=options.strip_file_prefix,
|
||||
)
|
||||
|
||||
lib_locations = get_lib_location_guesses(
|
||||
diff --git a/src/pip/_internal/req/req_install.py b/src/pip/_internal/req/req_install.py
|
||||
index a4834b00..d21530ac 100644
|
||||
--- a/src/pip/_internal/req/req_install.py
|
||||
+++ b/src/pip/_internal/req/req_install.py
|
||||
@@ -431,7 +431,8 @@ class InstallRequirement(object):
|
||||
prefix=None, # type: Optional[str]
|
||||
warn_script_location=True, # type: bool
|
||||
use_user_site=False, # type: bool
|
||||
- pycompile=True # type: bool
|
||||
+ pycompile=True, # type: bool
|
||||
+ strip_file_prefix=None # type: Optional[str]
|
||||
):
|
||||
# type: (...) -> None
|
||||
move_wheel_files(
|
||||
@@ -443,6 +444,7 @@ class InstallRequirement(object):
|
||||
pycompile=pycompile,
|
||||
isolated=self.isolated,
|
||||
warn_script_location=warn_script_location,
|
||||
+ strip_file_prefix=strip_file_prefix,
|
||||
)
|
||||
|
||||
# Things valid for sdists
|
||||
@@ -894,7 +896,8 @@ class InstallRequirement(object):
|
||||
prefix=None, # type: Optional[str]
|
||||
warn_script_location=True, # type: bool
|
||||
use_user_site=False, # type: bool
|
||||
- pycompile=True # type: bool
|
||||
+ pycompile=True, # type: bool
|
||||
+ strip_file_prefix=None # type: Optional[str]
|
||||
):
|
||||
# type: (...) -> None
|
||||
global_options = global_options if global_options is not None else []
|
||||
@@ -911,6 +914,7 @@ class InstallRequirement(object):
|
||||
self.source_dir, root=root, prefix=prefix, home=home,
|
||||
warn_script_location=warn_script_location,
|
||||
use_user_site=use_user_site, pycompile=pycompile,
|
||||
+ strip_file_prefix=strip_file_prefix,
|
||||
)
|
||||
self.install_succeeded = True
|
||||
return
|
||||
diff --git a/src/pip/_internal/wheel.py b/src/pip/_internal/wheel.py
|
||||
index 67bcc7f7..6470576b 100644
|
||||
--- a/src/pip/_internal/wheel.py
|
||||
+++ b/src/pip/_internal/wheel.py
|
||||
@@ -265,6 +265,7 @@ def get_csv_rows_for_installed(
|
||||
changed, # type: set
|
||||
generated, # type: List[str]
|
||||
lib_dir, # type: str
|
||||
+ strip_file_prefix=None, # type: Optional[str]
|
||||
):
|
||||
# type: (...) -> List[InstalledCSVRow]
|
||||
"""
|
||||
@@ -289,7 +290,11 @@ def get_csv_rows_for_installed(
|
||||
installed_rows.append(tuple(row))
|
||||
for f in generated:
|
||||
digest, length = rehash(f)
|
||||
- installed_rows.append((normpath(f, lib_dir), digest, str(length)))
|
||||
+ final_path = normpath(f, lib_dir)
|
||||
+ if strip_file_prefix and final_path.startswith(strip_file_prefix):
|
||||
+ final_path = os.path.join(os.sep,
|
||||
+ os.path.relpath(final_path, strip_file_prefix))
|
||||
+ installed_rows.append((final_path, digest, str(length)))
|
||||
for f in installed:
|
||||
installed_rows.append((installed[f], '', ''))
|
||||
return installed_rows
|
||||
@@ -306,7 +311,8 @@ def move_wheel_files(
|
||||
scheme=None, # type: Optional[Mapping[str, str]]
|
||||
isolated=False, # type: bool
|
||||
prefix=None, # type: Optional[str]
|
||||
- warn_script_location=True # type: bool
|
||||
+ warn_script_location=True, # type: bool
|
||||
+ strip_file_prefix=None # type: Optional[str]
|
||||
):
|
||||
# type: (...) -> None
|
||||
"""Install a wheel"""
|
||||
@@ -605,6 +611,7 @@ if __name__ == '__main__':
|
||||
outrows = get_csv_rows_for_installed(
|
||||
reader, installed=installed, changed=changed,
|
||||
generated=generated, lib_dir=lib_dir,
|
||||
+ strip_file_prefix=strip_file_prefix
|
||||
)
|
||||
writer = csv.writer(record_out)
|
||||
# Sort to simplify testing.
|
@ -15,8 +15,8 @@
|
||||
Name: python-%{srcname}
|
||||
# When updating, update the bundled libraries versions bellow!
|
||||
# You can use vendor_meta.sh in the dist git repo
|
||||
Version: 19.1.1
|
||||
Release: 8%{?dist}
|
||||
Version: 19.2.3
|
||||
Release: 1%{?dist}
|
||||
Summary: A tool for installing and managing Python packages
|
||||
|
||||
# We bundle a lot of libraries with pip, which itself is under MIT license.
|
||||
@ -73,9 +73,8 @@ Source2: https://github.com/pypa/pypa-docs-theme/archive/%{pypa_theme_com
|
||||
Source3: https://github.com/python/python-docs-theme/archive/2018.2.tar.gz
|
||||
%endif
|
||||
|
||||
# Patch until the following issue gets implemented upstream:
|
||||
# https://github.com/pypa/pip/issues/1351
|
||||
Patch0: allow-stripping-given-prefix-from-wheel-RECORD-files.patch
|
||||
# Fix expected output in test to not break with alpha/beta/rc Python versions
|
||||
Patch0: https://github.com/pypa/pip/pull/6788.patch
|
||||
|
||||
# Downstream only patch
|
||||
# Emit a warning to the user if pip install is run with root privileges
|
||||
@ -125,26 +124,26 @@ Packages" or "Pip Installs Python".
|
||||
%global bundled() %{expand:
|
||||
Provides: bundled(python%{1}dist(appdirs)) = 1.4.3
|
||||
Provides: bundled(python%{1}dist(CacheControl)) = 0.12.5
|
||||
Provides: bundled(python%{1}dist(certifi)) = 2019.3.9
|
||||
Provides: bundled(python%{1}dist(certifi)) = 2019.6.16
|
||||
Provides: bundled(python%{1}dist(chardet)) = 3.0.4
|
||||
Provides: bundled(python%{1}dist(colorama)) = 0.4.1
|
||||
Provides: bundled(python%{1}dist(distlib)) = 0.2.8
|
||||
Provides: bundled(python%{1}dist(distlib)) = 0.2.9.post0
|
||||
Provides: bundled(python%{1}dist(distro)) = 1.4.0
|
||||
Provides: bundled(python%{1}dist(html5lib)) = 1.0.1
|
||||
Provides: bundled(python%{1}dist(idna)) = 2.8
|
||||
Provides: bundled(python%{1}dist(ipaddress)) = 1.0.22
|
||||
Provides: bundled(python%{1}dist(lockfile)) = 0.12.2
|
||||
Provides: bundled(python%{1}dist(msgpack)) = 0.5.6
|
||||
Provides: bundled(python%{1}dist(msgpack)) = 0.6.1
|
||||
Provides: bundled(python%{1}dist(packaging)) = 19.0
|
||||
Provides: bundled(python%{1}dist(pep517)) = 0.5.0
|
||||
Provides: bundled(python%{1}dist(progress)) = 1.5
|
||||
Provides: bundled(python%{1}dist(pyparsing)) = 2.4.0
|
||||
Provides: bundled(python%{1}dist(pytoml)) = 0.1.20
|
||||
Provides: bundled(python%{1}dist(requests)) = 2.21.0
|
||||
Provides: bundled(python%{1}dist(requests)) = 2.22.0
|
||||
Provides: bundled(python%{1}dist(retrying)) = 1.3.3
|
||||
Provides: bundled(python%{1}dist(setuptools)) = 41.0.1
|
||||
Provides: bundled(python%{1}dist(six)) = 1.12.0
|
||||
Provides: bundled(python%{1}dist(urllib3)) = 1.24.1
|
||||
Provides: bundled(python%{1}dist(urllib3)) = 1.25.3
|
||||
Provides: bundled(python%{1}dist(webencodings)) = 0.5.1
|
||||
}
|
||||
|
||||
@ -349,7 +348,9 @@ ln -sf %{buildroot}%{_bindir}/pip3 _bin/pip
|
||||
%doc README.rst
|
||||
%if %{with doc}
|
||||
%{_mandir}/man1/pip.*
|
||||
%{_mandir}/man1/pip-*.*
|
||||
%{_mandir}/man1/pip3.*
|
||||
%{_mandir}/man1/pip3-*.*
|
||||
%endif
|
||||
%{_bindir}/pip
|
||||
%{_bindir}/pip3
|
||||
@ -374,6 +375,10 @@ ln -sf %{buildroot}%{_bindir}/pip3 _bin/pip
|
||||
%{python_wheeldir}/%{python_wheelname}
|
||||
|
||||
%changelog
|
||||
* Mon Sep 02 2019 Miro Hrončok <mhroncok@redhat.com> - 19.2.3-1
|
||||
- Update to 19.2.3 (#1742230)
|
||||
- Drop patch that should strip path prefixes from RECORD files, the paths are relative
|
||||
|
||||
* Wed Aug 21 2019 Petr Viktorin <pviktori@redhat.com> - 19.1.1-8
|
||||
- Remove python2-pip
|
||||
- Make pip bootstrap itself, rather than with an extra bootstrap RPM build
|
||||
|
@ -10,42 +10,20 @@ Date: Tue Sep 18 17:13:51 2018 +0200
|
||||
|
||||
Co-Authored-By: Michal Cyprian <m.cyprian@gmail.com>
|
||||
|
||||
diff --git a/src/pip/_internal/req/req_install.py b/src/pip/_internal/req/req_install.py
|
||||
index d21530a..0023a35 100644
|
||||
--- a/src/pip/_internal/req/req_install.py
|
||||
+++ b/src/pip/_internal/req/req_install.py
|
||||
@@ -29,7 +29,7 @@ from pip._internal.utils.hashes import Hashes
|
||||
from pip._internal.utils.logging import indent_log
|
||||
from pip._internal.utils.misc import (
|
||||
_make_build_dir, ask_path_exists, backup_dir, call_subprocess,
|
||||
- display_path, dist_in_site_packages, dist_in_usersite, ensure_dir,
|
||||
+ display_path, dist_in_install_path, dist_in_site_packages, dist_in_usersite, ensure_dir,
|
||||
get_installed_version, redact_password_from_url, rmtree,
|
||||
)
|
||||
from pip._internal.utils.packaging import get_metadata
|
||||
@@ -411,7 +411,7 @@ class InstallRequirement(object):
|
||||
"lack sys.path precedence to %s in %s" %
|
||||
(existing_dist.project_name, existing_dist.location)
|
||||
)
|
||||
- else:
|
||||
+ elif dist_in_install_path(existing_dist):
|
||||
self.conflicts_with = existing_dist
|
||||
return True
|
||||
|
||||
diff --git a/src/pip/_internal/resolve.py b/src/pip/_internal/resolve.py
|
||||
index 33f572f..88b68e1 100644
|
||||
--- a/src/pip/_internal/resolve.py
|
||||
+++ b/src/pip/_internal/resolve.py
|
||||
@@ -20,7 +20,7 @@ from pip._internal.exceptions import (
|
||||
)
|
||||
diff --git a/src/pip/_internal/legacy_resolve.py b/src/pip/_internal/legacy_resolve.py
|
||||
index 1d9229cb..3088d22d 100644
|
||||
--- a/src/pip/_internal/legacy_resolve.py
|
||||
+++ b/src/pip/_internal/legacy_resolve.py
|
||||
@@ -24,7 +24,7 @@ from pip._internal.exceptions import (
|
||||
from pip._internal.req.constructors import install_req_from_req_string
|
||||
from pip._internal.utils.logging import indent_log
|
||||
-from pip._internal.utils.misc import dist_in_usersite, ensure_dir
|
||||
+from pip._internal.utils.misc import dist_in_install_path, dist_in_usersite, ensure_dir
|
||||
from pip._internal.utils.packaging import check_dist_requires_python
|
||||
from pip._internal.utils.typing import MYPY_CHECK_RUNNING
|
||||
|
||||
@@ -154,7 +154,9 @@ class Resolver(object):
|
||||
from pip._internal.utils.misc import (
|
||||
- dist_in_usersite, ensure_dir, normalize_version_info,
|
||||
+ dist_in_install_path, dist_in_usersite, ensure_dir, normalize_version_info,
|
||||
)
|
||||
from pip._internal.utils.packaging import (
|
||||
check_requires_python, get_requires_python,
|
||||
@@ -219,7 +219,9 @@ class Resolver(object):
|
||||
"""
|
||||
# Don't uninstall the conflict if doing a user install and the
|
||||
# conflict is not a user install.
|
||||
@ -56,20 +34,42 @@ index 33f572f..88b68e1 100644
|
||||
req.conflicts_with = req.satisfied_by
|
||||
req.satisfied_by = None
|
||||
|
||||
diff --git a/src/pip/_internal/req/req_install.py b/src/pip/_internal/req/req_install.py
|
||||
index f5c93504..1096c397 100644
|
||||
--- a/src/pip/_internal/req/req_install.py
|
||||
+++ b/src/pip/_internal/req/req_install.py
|
||||
@@ -27,7 +27,7 @@ from pip._internal.utils.logging import indent_log
|
||||
from pip._internal.utils.marker_files import PIP_DELETE_MARKER_FILENAME
|
||||
from pip._internal.utils.misc import (
|
||||
_make_build_dir, ask_path_exists, backup_dir, call_subprocess,
|
||||
- display_path, dist_in_site_packages, dist_in_usersite, ensure_dir,
|
||||
+ display_path, dist_in_install_path, dist_in_site_packages, dist_in_usersite, ensure_dir,
|
||||
get_installed_version, redact_password_from_url, rmtree,
|
||||
)
|
||||
from pip._internal.utils.packaging import get_metadata
|
||||
@@ -427,7 +427,7 @@ class InstallRequirement(object):
|
||||
"lack sys.path precedence to %s in %s" %
|
||||
(existing_dist.project_name, existing_dist.location)
|
||||
)
|
||||
- else:
|
||||
+ elif dist_in_install_path(existing_dist):
|
||||
self.conflicts_with = existing_dist
|
||||
return True
|
||||
|
||||
diff --git a/src/pip/_internal/utils/misc.py b/src/pip/_internal/utils/misc.py
|
||||
index 84605ee..0e4ba93 100644
|
||||
index 61f74dc8..ffa8042c 100644
|
||||
--- a/src/pip/_internal/utils/misc.py
|
||||
+++ b/src/pip/_internal/utils/misc.py
|
||||
@@ -30,7 +30,7 @@ from pip._vendor.six.moves.urllib.parse import unquote as urllib_unquote
|
||||
|
||||
from pip import __version__
|
||||
from pip._internal.exceptions import CommandError, InstallationError
|
||||
from pip._internal.locations import (
|
||||
running_under_virtualenv, site_packages, user_site, virtualenv_no_global,
|
||||
- write_delete_marker_file,
|
||||
+ write_delete_marker_file, distutils_scheme,
|
||||
)
|
||||
-from pip._internal.locations import site_packages, user_site
|
||||
+from pip._internal.locations import distutils_scheme, site_packages, user_site
|
||||
from pip._internal.utils.compat import (
|
||||
WINDOWS, console_to_str, expanduser, stdlib_pkgs,
|
||||
@@ -355,6 +355,16 @@ def dist_in_site_packages(dist):
|
||||
WINDOWS, console_to_str, expanduser, stdlib_pkgs, str_to_display,
|
||||
)
|
||||
@@ -454,6 +454,16 @@ def dist_in_site_packages(dist):
|
||||
).startswith(normalize_path(site_packages))
|
||||
|
||||
|
||||
|
4
sources
4
sources
@ -1,4 +1,4 @@
|
||||
SHA512 (pip-19.1.1.tar.gz) = b35598fc6077af44d69f32bc3bc4b28630b1761a31b6b814c59069adbea98bdd68071471bf5ebd28551aae8e970b882200938f6751135f246dc8228f799604a3
|
||||
SHA512 (pip-19.1.1-tests.tar.gz) = e67d49c87dc06ef1c45733623280571089307f2e4151c6e189d2f286c154c59d0c83e6a252ac5bd677ece0ce03294f909aa9eed128f0795f062224fcbf21c5d7
|
||||
SHA512 (pip-19.2.3.tar.gz) = 64ab4ece6da526c9d1b24e73a9c0ca0a38d0fb1525bf9981177342a8b0902ae825ec8f3dabd9ce00dcf0f010aaabf4177c9146084668ce505e0c382c322948c8
|
||||
SHA512 (pip-19.2.3-tests.tar.gz) = d4052d83e20fe276d251a80d8d33c33568570d5f26038847f0e5fba34a48ae3d5318b31439f8582d337245f38472495db221d7f4bf39eb9c98181f2f8aecad36
|
||||
SHA512 (d2e63fbfc62af3b7050f619b2f5bb8658985b931.tar.gz) = fc7b11c5cbf6322469ce2eaca2a8d7eb60b17398d316f7465ab5d3d38dabd00ee22a3da7437a28f6312f0115f77f2df0d8bf0abc671e055eef06356c94283409
|
||||
SHA512 (2018.2.tar.gz) = 4c09c43a70ecb3ca3bc9445b01bf209eb382e41d9c969145696dea38551992ed88fd9b725a1264380f3dbdf8acdaf5ada3ef86b44255cdfbdbe4a01a1630912d
|
||||
|
Loading…
Reference in New Issue
Block a user