From a7fc70455e4f49ad4e63bbca785aa05f3caf772f Mon Sep 17 00:00:00 2001 From: Georgy Pchelkin Date: Wed, 9 Mar 2022 16:59:22 +0300 Subject: [PATCH 1/2] --proxy option requires scheme, does not work without it see also: https://github.com/pypa/pip/commit/2b2ca40ccc44a3e1873f77b770b359e66349120b --- docs/html/user_guide.rst | 2 +- src/pip/_internal/cli/cmdoptions.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/html/user_guide.rst b/docs/html/user_guide.rst index 059fd7cdc35..aa5d41c8cfe 100644 --- a/docs/html/user_guide.rst +++ b/docs/html/user_guide.rst @@ -84,7 +84,7 @@ in many corporate environments requires an outbound HTTP proxy server. pip can be configured to connect through a proxy server in various ways: * using the ``--proxy`` command-line option to specify a proxy in the form - ``[user:passwd@]proxy.server:port`` + ``scheme://[user:passwd@]proxy.server:port`` * using ``proxy`` in a :ref:`config-file` * by setting the standard environment-variables ``http_proxy``, ``https_proxy`` and ``no_proxy``. diff --git a/src/pip/_internal/cli/cmdoptions.py b/src/pip/_internal/cli/cmdoptions.py index 71b1d190691..64bd47d2b68 100644 --- a/src/pip/_internal/cli/cmdoptions.py +++ b/src/pip/_internal/cli/cmdoptions.py @@ -272,7 +272,7 @@ class PipOption(Option): dest="proxy", type="str", default="", - help="Specify a proxy in the form [user:passwd@]proxy.server:port.", + help="Specify a proxy in the form scheme://[user:passwd@]proxy.server:port.", ) retries: Callable[..., Option] = partial( From 57b69c642b5f88c81ef9bf4ffc4e5ae201c3a357 Mon Sep 17 00:00:00 2001 From: Georgy Pchelkin Date: Wed, 9 Mar 2022 17:02:39 +0300 Subject: [PATCH 2/2] add news entry --- news/10951.doc.rst | 1 + 1 file changed, 1 insertion(+) create mode 100644 news/10951.doc.rst diff --git a/news/10951.doc.rst b/news/10951.doc.rst new file mode 100644 index 00000000000..f132abd111f --- /dev/null +++ b/news/10951.doc.rst @@ -0,0 +1 @@ +Add ``scheme://`` requirement to ``--proxy`` option's description