Browse code

Do not call update.py from a venv

198580 backported a change to install requirements into a venv
and call update.py from that venv. stable/juno's pip facilities do
not contain the venv support. openstack-requirements ends up installed
into the system but we're calling update.py from a bare venv. This
prevents 198146 from merging, which is blocking stable/juno merges
and client releases.

Rather than backport all of the venv support into stable/juno
this late in its life, this just removes the venv assumption and relies on
requirements ending up installed system-wide like it is now.

Change-Id: I11c9583be5d71a0d4797ea6ff25c245f1aadf0a5

Adam Gandelman authored on 2015/07/24 09:49:57
Showing 2 changed files
... ...
@@ -1666,7 +1666,7 @@ function setup_package_with_req_sync {
1666 1666
 
1667 1667
     if [[ $update_requirements != "changed" ]]; then
1668 1668
         (cd $REQUIREMENTS_DIR; \
1669
-            ./.venv/bin/python update.py $project_dir)
1669
+            python update.py $project_dir)
1670 1670
     fi
1671 1671
 
1672 1672
     setup_package $project_dir $flags
... ...
@@ -30,14 +30,7 @@ function install_infra {
30 30
     local PIP_VIRTUAL_ENV="$REQUIREMENTS_DIR/.venv"
31 31
     # bring down global requirements
32 32
     git_clone $REQUIREMENTS_REPO $REQUIREMENTS_DIR $REQUIREMENTS_BRANCH
33
-    [ ! -d $PIP_VIRTUAL_ENV ] && virtualenv $PIP_VIRTUAL_ENV
34
-    # We don't care about testing git pbr in the requirements venv.
35
-    PIP_VIRTUAL_ENV=$PIP_VIRTUAL_ENV pip_install -U pbr
36
-    PIP_VIRTUAL_ENV=$PIP_VIRTUAL_ENV pip_install $REQUIREMENTS_DIR
37
-
38
-    # Unset the PIP_VIRTUAL_ENV so that PBR does not end up trapped
39
-    # down the VENV well
40
-    unset PIP_VIRTUAL_ENV
33
+    pip_install $REQUIREMENTS_DIR
41 34
 
42 35
     # Install pbr
43 36
     if use_library_from_git "pbr"; then