Browse code

Pip install fails because of --use-mirrors parameter

Having --use-mirrors parameter in pip commands causes pip to hang on
some distros.

Pypi uses CDN for long time already, so there's no point to keep this
parameter no more.

Wipe PIP_USE_MIRRORS out of the "function" file.

Change-Id: I70adaf6591834af2482e09eb7f8f9f60df8e7692
Closes-Bug: #1069309

Roman Gorodeckij authored on 2013/08/07 22:20:36
Showing 1 changed files
... ...
@@ -944,13 +944,9 @@ function pip_install {
944 944
         CMD_PIP=$(get_pip_command)
945 945
     fi
946 946
 
947
-    if is_fedora && [[ $DISTRO =~ (rhel6) ]]; then
948
-        # RHEL6 pip by default doesn't have this (was introduced
949
-        # around 0.8.1 or so)
950
-        PIP_USE_MIRRORS=${PIP_USE_MIRRORS:-False}
951
-    else
952
-        PIP_USE_MIRRORS=${PIP_USE_MIRRORS:-True}
953
-    fi
947
+    # Mirror option not needed anymore because pypi has CDN available,
948
+    # but it's useful in certain circumstances
949
+    PIP_USE_MIRRORS=${PIP_USE_MIRRORS:-False}
954 950
     if [[ "$PIP_USE_MIRRORS" != "False" ]]; then
955 951
         PIP_MIRROR_OPT="--use-mirrors"
956 952
     fi