Repository: aurora
Updated Branches:
  refs/heads/master f93de947e -> 27b5e25c5


Invoke pip as a python module rather than directly.

Bugs closed: AURORA-1309

Reviewed at https://reviews.apache.org/r/33955/


Project: http://git-wip-us.apache.org/repos/asf/aurora/repo
Commit: http://git-wip-us.apache.org/repos/asf/aurora/commit/27b5e25c
Tree: http://git-wip-us.apache.org/repos/asf/aurora/tree/27b5e25c
Diff: http://git-wip-us.apache.org/repos/asf/aurora/diff/27b5e25c

Branch: refs/heads/master
Commit: 27b5e25c5a9c5a43a781ee4fb9423160d70c13c8
Parents: f93de94
Author: Bill Farner <[email protected]>
Authored: Thu May 7 14:18:48 2015 -0700
Committer: Bill Farner <[email protected]>
Committed: Thu May 7 14:18:48 2015 -0700

----------------------------------------------------------------------
 build-support/jenkins/build.sh                 |  2 +-
 build-support/pex                              |  2 +-
 build-support/python/checkstyle                |  2 +-
 build-support/python/isort                     |  2 +-
 build-support/python/make-pycharm-virtualenv   | 10 +++++-----
 build-support/python/update-pants-requirements |  2 +-
 pants                                          |  2 +-
 rbt                                            |  3 ++-
 8 files changed, 13 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/aurora/blob/27b5e25c/build-support/jenkins/build.sh
----------------------------------------------------------------------
diff --git a/build-support/jenkins/build.sh b/build-support/jenkins/build.sh
index 229fc9d..5606bb1 100755
--- a/build-support/jenkins/build.sh
+++ b/build-support/jenkins/build.sh
@@ -25,7 +25,7 @@ date
 export PIP_DEFAULT_TIMEOUT=60
 mkdir -p third_party
 # We omit mesos.native here since we don't actually build or use it in our 
unit tests.
-pip install -d third_party -r <(grep -v mesos.native 
3rdparty/python/requirements.txt)
+python -m pip install -d third_party -r <(grep -v mesos.native 
3rdparty/python/requirements.txt)
 
 # Run Python style checks
 ./build-support/python/isort-check

http://git-wip-us.apache.org/repos/asf/aurora/blob/27b5e25c/build-support/pex
----------------------------------------------------------------------
diff --git a/build-support/pex b/build-support/pex
index 61fbc91..54e31f1 100755
--- a/build-support/pex
+++ b/build-support/pex
@@ -35,7 +35,7 @@ if ! [ -f "$HERE/pex.venv/BOOTSTRAPPED" ] || \
   rm -fr "$HERE/pex.venv"
   "$HERE/virtualenv" "$HERE/pex.venv"
   source "$HERE/pex.venv/bin/activate"
-  pip install "twitter.common.python==$TWITTER_COMMON_PYTHON_VERSION"
+  python -m pip install "twitter.common.python==$TWITTER_COMMON_PYTHON_VERSION"
   echo $TWITTER_COMMON_PYTHON_VERSION > "$HERE"/pex.venv/BOOTSTRAPPED
 fi
 source "$HERE/pex.venv/bin/activate"

http://git-wip-us.apache.org/repos/asf/aurora/blob/27b5e25c/build-support/python/checkstyle
----------------------------------------------------------------------
diff --git a/build-support/python/checkstyle b/build-support/python/checkstyle
index ee8c8d5..61acc22 100755
--- a/build-support/python/checkstyle
+++ b/build-support/python/checkstyle
@@ -26,7 +26,7 @@ if ! [ -f "$HERE/checkstyle.venv/BOOTSTRAPPED" ] || \
   rm -fr "$HERE/checkstyle.venv"
   "$HERE/../virtualenv" "$HERE/checkstyle.venv"
   source "$HERE/checkstyle.venv/bin/activate"
-  pip install "twitter.checkstyle==$CHECKSTYLE_VERSION"
+  python -m pip install "twitter.checkstyle==$CHECKSTYLE_VERSION"
   echo $CHECKSTYLE_VERSION > "$HERE/checkstyle.venv/BOOTSTRAPPED"
 fi
 

http://git-wip-us.apache.org/repos/asf/aurora/blob/27b5e25c/build-support/python/isort
----------------------------------------------------------------------
diff --git a/build-support/python/isort b/build-support/python/isort
index 2f697be..44f9659 100755
--- a/build-support/python/isort
+++ b/build-support/python/isort
@@ -24,7 +24,7 @@ if ! [ -f "$HERE/isort.venv/BOOTSTRAPPED" ] || \
   rm -fr "$HERE/isort.venv"
   "$HERE/../virtualenv" "$HERE/isort.venv"
   source "$HERE/isort.venv/bin/activate"
-  pip install "isort==$ISORT_VERSION"
+  python -m pip install "isort==$ISORT_VERSION"
   echo $ISORT_VERSION > "$HERE/isort.venv/BOOTSTRAPPED"
 fi
 

http://git-wip-us.apache.org/repos/asf/aurora/blob/27b5e25c/build-support/python/make-pycharm-virtualenv
----------------------------------------------------------------------
diff --git a/build-support/python/make-pycharm-virtualenv 
b/build-support/python/make-pycharm-virtualenv
index 84dfb64..05a16d0 100755
--- a/build-support/python/make-pycharm-virtualenv
+++ b/build-support/python/make-pycharm-virtualenv
@@ -25,20 +25,20 @@ pushd "$BUILDROOT"
   ./pants setup-py api/src/main/thrift/org/apache/aurora/gen:py-thrift-packaged
   ./pants setup-py api/src/main/thrift/org/apache/thermos:py-thrift
   source build-support/pants.venv/bin/activate
-    pytest_requirement=$(pip freeze | grep pytest==)
-    pytest_cov_requirement=$(pip freeze | grep pytest-cov==)
+    pytest_requirement=$(python -m pip freeze | grep pytest==)
+    pytest_cov_requirement=$(python -m pip freeze | grep pytest-cov==)
   deactivate
   rm -rf "$VENV_DIR"
   ./build-support/virtualenv "$VENV_DIR"
   source $VENV_DIR/bin/activate
     # NOTE: PyCharm navigation (ctrl-click) doesn't work without --egg - it 
gets confused by
     # the namespace packages in twitter.common.
-    pip install --egg -r requirements.txt
-    pip install --egg -f dist \
+    python -m pip install --egg -r requirements.txt
+    python -m pip install --egg -f dist \
       apache.gen.aurora==$(< .auroraversion) \
       apache.gen.thermos==$(<.auroraversion)
     # Use same py.test version embedded into pants
-    pip install $pytest_requirement $pytest_cov_requirement
+    python -m pip install $pytest_requirement $pytest_cov_requirement
   deactivate
 popd
 

http://git-wip-us.apache.org/repos/asf/aurora/blob/27b5e25c/build-support/python/update-pants-requirements
----------------------------------------------------------------------
diff --git a/build-support/python/update-pants-requirements 
b/build-support/python/update-pants-requirements
index ae210bc..82f7c51 100755
--- a/build-support/python/update-pants-requirements
+++ b/build-support/python/update-pants-requirements
@@ -23,7 +23,7 @@ PANTS_VENV_PATH="$BUILD_SUPPORT/pants-requirements.venv"
 rm -rf "$PANTS_VENV_PATH"
 "$BUILD_SUPPORT/virtualenv" "$PANTS_VENV_PATH"
 source "$PANTS_VENV_PATH/bin/activate"
-pip install pantsbuild.pants==$PANTS_VERSION
+python -m pip install pantsbuild.pants==$PANTS_VERSION
 cat <<EOF > "$BUILD_SUPPORT/pants_requirements.txt"
 #
 # This file is generated automatically. Do not modify it manually! Instead it

http://git-wip-us.apache.org/repos/asf/aurora/blob/27b5e25c/pants
----------------------------------------------------------------------
diff --git a/pants b/pants
index 9dd3188..6f3526e 100755
--- a/pants
+++ b/pants
@@ -28,7 +28,7 @@ if ! [ -f "$HERE/build-support/pants.venv/BOOTSTRAPPED" ] || \
   # TODO(ksweeney): remove this hack when 
https://github.com/pantsbuild/pex/issues/21 is fixed.
   rm -fr "$HERE/build-support/pants.venv/local"
   source "$HERE/build-support/pants.venv/bin/activate"
-  pip install -r "$PANTS_REQUIREMENTS"
+  python -m pip install -r "$PANTS_REQUIREMENTS"
   echo $PANTS_VERSION > "$HERE/build-support/pants.venv/BOOTSTRAPPED"
 fi
 source "$HERE/build-support/pants.venv/bin/activate"

http://git-wip-us.apache.org/repos/asf/aurora/blob/27b5e25c/rbt
----------------------------------------------------------------------
diff --git a/rbt b/rbt
index c149249..c082ab4 100755
--- a/rbt
+++ b/rbt
@@ -25,7 +25,8 @@ if ! [ -f "$HERE/build-support/rbt.venv/BOOTSTRAPPED" ] || \
   "$HERE/build-support/virtualenv" "$HERE/build-support/rbt.venv"
   source "$HERE/build-support/rbt.venv/bin/activate"
   # Workaround for 
https://groups.google.com/forum/#!topic/reviewboard/rqdoykc-rpo
-  pip install "RBTools==$RBTOOLS_VERSION" --allow-external RBTools 
--allow-unverified RBTools
+  python -m pip install "RBTools==$RBTOOLS_VERSION" \
+      --allow-external RBTools --allow-unverified RBTools
   echo $RBTOOLS_VERSION > "$HERE/build-support/rbt.venv/BOOTSTRAPPED"
 fi
 source "$HERE/build-support/rbt.venv/bin/activate"

Reply via email to