Skip to content

Commit

Permalink
Fix travis builds (#73)
Browse files Browse the repository at this point in the history
* Fixes Travis builds by installing cvxpy via conda
  • Loading branch information
demianw authored and rutgerfick committed Sep 22, 2019
1 parent fc3f5a1 commit dcfc39a
Showing 1 changed file with 19 additions and 16 deletions.
35 changes: 19 additions & 16 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

env:
global:
- CONDA_DEPS="pip flake8 nose coverage pytest numpy scipy matplotlib seaborn pandas h5py" PIP_DEPS="coveralls pytest-cov codecov pathlib travis-sphinx boto"
- CONDA_DEPS="pip flake8 nose coverage pytest numpy scipy matplotlib seaborn pandas h5py cvxpy nbconvert entrypoints" PIP_DEPS="coveralls pytest-cov codecov pathlib travis-sphinx boto"

matrix:
include:
Expand All @@ -25,30 +25,33 @@ matrix:
# - MINICONDA_URL="https://repo.continuum.io/miniconda/Miniconda3-latest-MacOSX-x86_64.sh"
- os: linux
python: 2.7
env:
- PYTHON_VERSION=2.7
- MINICONDA_URL="https://repo.continuum.io/miniconda/Miniconda2-latest-Linux-x86_64.sh"
- os: linux
python: 3.5
env:
- PYTHON_VERSION=3.5
- MINICONDA_URL="https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh"

- os: linux
python: 3.6
- os: linux
python: 3.7

before_install:
- export MINICONDA=$HOME/miniconda
- export PATH="$MINICONDA/bin:$PATH"
- hash -r
- echo $MINICONDA_URL
- wget $MINICONDA_URL -O miniconda.sh;
- if [[ "$TRAVIS_PYTHON_VERSION" == "2.7" ]]; then
wget https://repo.continuum.io/miniconda/Miniconda2-latest-Linux-x86_64.sh -O miniconda.sh;
else
wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh;
fi
- export PYTHON_VERSION=$TRAVIS_PYTHON_VERSION
- bash miniconda.sh -b -f -p $MINICONDA;
- conda config --set always_yes yes
- conda update conda
- source "$MINICONDA/etc/profile.d/conda.sh"
- conda config --set always_yes yes --set changeps1 no
- conda update -q conda
- conda info -a
- conda install nbconvert
- conda install entrypoints
- conda config --add channels conda-forge
- conda install python=$PYTHON_VERSION $CONDA_DEPS
- conda config --append channels conda-forge
- conda config --append channels cvxgrp
- conda config --set channel_priority strict
- conda create -n testenv python=$PYTHON_VERSION $CONDA_DEPS
- conda activate testenv
- travis_retry pip install $PIP_DEPS

install:
Expand Down

0 comments on commit dcfc39a

Please sign in to comment.