mirror of
https://github.com/python/cpython.git
synced 2025-07-17 16:25:18 +00:00
Update pip to the released 1.5
This commit is contained in:
parent
c70d4f4d79
commit
f7f58f8db5
3 changed files with 10 additions and 16 deletions
|
@ -4,15 +4,13 @@ import pkgutil
|
||||||
import sys
|
import sys
|
||||||
import tempfile
|
import tempfile
|
||||||
|
|
||||||
# TODO: Remove the --pre flag when a pip 1.5 final copy is available
|
|
||||||
|
|
||||||
|
|
||||||
__all__ = ["version", "bootstrap"]
|
__all__ = ["version", "bootstrap"]
|
||||||
|
|
||||||
|
|
||||||
_SETUPTOOLS_VERSION = "2.0.2"
|
_SETUPTOOLS_VERSION = "2.0.2"
|
||||||
|
|
||||||
_PIP_VERSION = "1.5rc4"
|
_PIP_VERSION = "1.5"
|
||||||
|
|
||||||
# pip currently requires ssl support, so we try to provide a nicer
|
# pip currently requires ssl support, so we try to provide a nicer
|
||||||
# error message when that is missing (http://bugs.python.org/issue19744)
|
# error message when that is missing (http://bugs.python.org/issue19744)
|
||||||
|
@ -102,11 +100,7 @@ def bootstrap(*, root=None, upgrade=False, user=False,
|
||||||
additional_paths.append(os.path.join(tmpdir, wheel_name))
|
additional_paths.append(os.path.join(tmpdir, wheel_name))
|
||||||
|
|
||||||
# Construct the arguments to be passed to the pip command
|
# Construct the arguments to be passed to the pip command
|
||||||
args = [
|
args = ["install", "--no-index", "--find-links", tmpdir]
|
||||||
"install", "--no-index", "--find-links", tmpdir,
|
|
||||||
# Temporary until pip 1.5 is final
|
|
||||||
"--pre",
|
|
||||||
]
|
|
||||||
if root:
|
if root:
|
||||||
args += ["--root", root]
|
args += ["--root", root]
|
||||||
if upgrade:
|
if upgrade:
|
||||||
|
|
Binary file not shown.
|
@ -52,7 +52,7 @@ class TestBootstrap(EnsurepipMixin, unittest.TestCase):
|
||||||
self.run_pip.assert_called_once_with(
|
self.run_pip.assert_called_once_with(
|
||||||
[
|
[
|
||||||
"install", "--no-index", "--find-links",
|
"install", "--no-index", "--find-links",
|
||||||
unittest.mock.ANY, "--pre", "setuptools", "pip",
|
unittest.mock.ANY, "setuptools", "pip",
|
||||||
],
|
],
|
||||||
unittest.mock.ANY,
|
unittest.mock.ANY,
|
||||||
)
|
)
|
||||||
|
@ -67,7 +67,7 @@ class TestBootstrap(EnsurepipMixin, unittest.TestCase):
|
||||||
self.run_pip.assert_called_once_with(
|
self.run_pip.assert_called_once_with(
|
||||||
[
|
[
|
||||||
"install", "--no-index", "--find-links",
|
"install", "--no-index", "--find-links",
|
||||||
unittest.mock.ANY, "--pre", "--root", "/foo/bar/",
|
unittest.mock.ANY, "--root", "/foo/bar/",
|
||||||
"setuptools", "pip",
|
"setuptools", "pip",
|
||||||
],
|
],
|
||||||
unittest.mock.ANY,
|
unittest.mock.ANY,
|
||||||
|
@ -80,7 +80,7 @@ class TestBootstrap(EnsurepipMixin, unittest.TestCase):
|
||||||
self.run_pip.assert_called_once_with(
|
self.run_pip.assert_called_once_with(
|
||||||
[
|
[
|
||||||
"install", "--no-index", "--find-links",
|
"install", "--no-index", "--find-links",
|
||||||
unittest.mock.ANY, "--pre", "--user", "setuptools", "pip",
|
unittest.mock.ANY, "--user", "setuptools", "pip",
|
||||||
],
|
],
|
||||||
unittest.mock.ANY,
|
unittest.mock.ANY,
|
||||||
)
|
)
|
||||||
|
@ -92,7 +92,7 @@ class TestBootstrap(EnsurepipMixin, unittest.TestCase):
|
||||||
self.run_pip.assert_called_once_with(
|
self.run_pip.assert_called_once_with(
|
||||||
[
|
[
|
||||||
"install", "--no-index", "--find-links",
|
"install", "--no-index", "--find-links",
|
||||||
unittest.mock.ANY, "--pre", "--upgrade", "setuptools", "pip",
|
unittest.mock.ANY, "--upgrade", "setuptools", "pip",
|
||||||
],
|
],
|
||||||
unittest.mock.ANY,
|
unittest.mock.ANY,
|
||||||
)
|
)
|
||||||
|
@ -104,7 +104,7 @@ class TestBootstrap(EnsurepipMixin, unittest.TestCase):
|
||||||
self.run_pip.assert_called_once_with(
|
self.run_pip.assert_called_once_with(
|
||||||
[
|
[
|
||||||
"install", "--no-index", "--find-links",
|
"install", "--no-index", "--find-links",
|
||||||
unittest.mock.ANY, "--pre", "-v", "setuptools", "pip",
|
unittest.mock.ANY, "-v", "setuptools", "pip",
|
||||||
],
|
],
|
||||||
unittest.mock.ANY,
|
unittest.mock.ANY,
|
||||||
)
|
)
|
||||||
|
@ -116,7 +116,7 @@ class TestBootstrap(EnsurepipMixin, unittest.TestCase):
|
||||||
self.run_pip.assert_called_once_with(
|
self.run_pip.assert_called_once_with(
|
||||||
[
|
[
|
||||||
"install", "--no-index", "--find-links",
|
"install", "--no-index", "--find-links",
|
||||||
unittest.mock.ANY, "--pre", "-vv", "setuptools", "pip",
|
unittest.mock.ANY, "-vv", "setuptools", "pip",
|
||||||
],
|
],
|
||||||
unittest.mock.ANY,
|
unittest.mock.ANY,
|
||||||
)
|
)
|
||||||
|
@ -128,7 +128,7 @@ class TestBootstrap(EnsurepipMixin, unittest.TestCase):
|
||||||
self.run_pip.assert_called_once_with(
|
self.run_pip.assert_called_once_with(
|
||||||
[
|
[
|
||||||
"install", "--no-index", "--find-links",
|
"install", "--no-index", "--find-links",
|
||||||
unittest.mock.ANY, "--pre", "-vvv", "setuptools", "pip",
|
unittest.mock.ANY, "-vvv", "setuptools", "pip",
|
||||||
],
|
],
|
||||||
unittest.mock.ANY,
|
unittest.mock.ANY,
|
||||||
)
|
)
|
||||||
|
@ -286,7 +286,7 @@ class TestBootstrappingMainFunction(EnsurepipMixin, unittest.TestCase):
|
||||||
self.run_pip.assert_called_once_with(
|
self.run_pip.assert_called_once_with(
|
||||||
[
|
[
|
||||||
"install", "--no-index", "--find-links",
|
"install", "--no-index", "--find-links",
|
||||||
unittest.mock.ANY, "--pre", "setuptools", "pip",
|
unittest.mock.ANY, "setuptools", "pip",
|
||||||
],
|
],
|
||||||
unittest.mock.ANY,
|
unittest.mock.ANY,
|
||||||
)
|
)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue