Skip to content

Commit

Permalink
Use python -m to run utilities on Travis
Browse files Browse the repository at this point in the history
It's more reliable than just running the utility.
  • Loading branch information
dopplershift committed Sep 19, 2019
1 parent f8bc931 commit d1595e1
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions .travis.yml
Expand Up @@ -68,7 +68,7 @@ matrix:
before_install:
# We hard-code the sphinx_rtd_theme to lock in our build with patch for
# version chooser
- pip install --upgrade pip;
- python -m pip install --upgrade pip;
- if [[ ! -f $HOME/local/lib/libproj.so ]]; then
wget http://download.osgeo.org/proj/proj-4.9.3.tar.gz;
tar xf proj-4.9.3.tar.gz;
Expand Down Expand Up @@ -97,18 +97,18 @@ before_install:
fi;
- mkdir $WHEELDIR;
# These need to be downloaded because when we run builds later we disable the index
- pip download -d $WHEELDIR -f $WHEELHOUSE setuptools wheel setuptools_scm;
- python -m pip download -d $WHEELDIR -f $WHEELHOUSE setuptools wheel setuptools_scm;
# Cython needs to be installed before even downloading CartoPy
- pip install Cython;
- pip download -d $WHEELDIR ".[$EXTRA_INSTALLS]" $EXTRA_PACKAGES -f $WHEELHOUSE $PRE $VERSIONS;
- python -m pip install Cython;
- python -m pip download -d $WHEELDIR ".[$EXTRA_INSTALLS]" $EXTRA_PACKAGES -f $WHEELHOUSE $PRE $VERSIONS;
- touch $WHEELDIR/download_marker && ls -lrt $WHEELDIR;
- travis_wait pip wheel -w $WHEELDIR $EXTRA_PACKAGES -f $WHEELHOUSE $PRE $VERSIONS;
- pip install $EXTRA_PACKAGES --upgrade --upgrade-strategy=eager --no-index -f file://$PWD/$WHEELDIR $VERSIONS;
- travis_wait 30 pip wheel -w $WHEELDIR ".[$EXTRA_INSTALLS]" $EXTRA_PACKAGES -f $WHEELHOUSE $PRE $VERSIONS;
- travis_wait python -m pip wheel -w $WHEELDIR $EXTRA_PACKAGES -f $WHEELHOUSE $PRE $VERSIONS;
- python -m pip install $EXTRA_PACKAGES --upgrade --upgrade-strategy=eager --no-index -f file://$PWD/$WHEELDIR $VERSIONS;
- travis_wait 30 python -m pip wheel -w $WHEELDIR ".[$EXTRA_INSTALLS]" $EXTRA_PACKAGES -f $WHEELHOUSE $PRE $VERSIONS;
- rm -f $WHEELDIR/MetPy*.whl;

install:
- pip install ".[$EXTRA_INSTALLS]" --upgrade --upgrade-strategy=eager --no-index $PRE -f file://$PWD/$WHEELDIR $VERSIONS;
- python -m pip install ".[$EXTRA_INSTALLS]" --upgrade --upgrade-strategy=eager --no-index $PRE -f file://$PWD/$WHEELDIR $VERSIONS;

script:
- if [[ $TASK == "docs" ]]; then
Expand All @@ -129,7 +129,7 @@ script:
fi;
else
flake8 --version;
pytest $TEST_OUTPUT_CONTROL $TEST_OPTS;
python -m pytest $TEST_OUTPUT_CONTROL $TEST_OPTS;
fi

after_script:
Expand Down

0 comments on commit d1595e1

Please sign in to comment.