Skip to content

Commit

Permalink
Update CI (#1141)
Browse files Browse the repository at this point in the history
* Do not run CI on latest and latest-tmp tags

* Update CI images, run coverage only on py37

* Update deprecated wheel tag in setup.cfg

* Update py37 images
  • Loading branch information
rly authored Jan 16, 2020
1 parent bc9254b commit d631fe5
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 40 deletions.
42 changes: 26 additions & 16 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,12 @@ references:
# While pip installing tox does not output by default. Circle thinks task is dead after 10 min.
no_output_timeout: 30m
- run:
name: Run coverage and submit to codecov-io
name: Run coverage and submit to codecov-io if COVERAGE_TOX_ENV != ""
command: |
. ../venv/bin/activate
tox -e $COVERAGE_TOX_ENV
if [[ "${COVERAGE_TOX_ENV}" != "" ]]; then
tox -e $COVERAGE_TOX_ENV
fi
- run:
name: Build wheel and source distribution
command: |
Expand Down Expand Up @@ -75,7 +77,7 @@ references:
conda config --set always_yes yes --set changeps1 no
conda config --add channels conda-forge
conda install python=$CONDA_PYTHON_VER
conda install virtualenv==16.0.0
conda install virtualenv
conda install tox
- run:
name: Run the tests
Expand Down Expand Up @@ -114,12 +116,15 @@ references:
no_filters: &no_filters
filters:
tags:
only: /.*/
ignore:
# exclude tags created by "ci_addons publish_github_release"
- /^latest$/
- /^latest-tmp$/

jobs:
flake8:
docker:
- image: circleci/python:3.6.3-jessie
- image: circleci/python:3.8.1-buster
steps:
- checkout
- run:
Expand All @@ -129,31 +134,31 @@ jobs:

python35:
docker:
- image: circleci/python:3.5.7-jessie
- image: circleci/python:3.5.9-stretch
environment:
- TEST_TOX_ENV: "py35"
- COVERAGE_TOX_ENV: "coverage-py35"
- COVERAGE_TOX_ENV: ""
- BUILD_TOX_ENV: "build-py35"
- TEST_WHEELINSTALL_ENV: "wheelinstall-py35"
<<: *ci-steps

python36:
docker:
- image: circleci/python:3.6.3-jessie
- image: circleci/python:3.6.10-stretch
environment:
- TEST_TOX_ENV: "py36"
- COVERAGE_TOX_ENV: "coverage-py36"
- COVERAGE_TOX_ENV: ""
- BUILD_TOX_ENV: "build-py36"
- TEST_WHEELINSTALL_ENV: "wheelinstall-py36"
- UPLOAD_WHEELS: "true"
<<: *ci-steps

python37:
docker:
- image: circleci/python:3.7.0-stretch
- image: circleci/python:3.7.6-stretch
environment:
- TEST_TOX_ENV: "py37"
- COVERAGE_TOX_ENV: "coverage-py37"
- COVERAGE_TOX_ENV: "coverage"
- BUILD_TOX_ENV: "build-py37"
- TEST_WHEELINSTALL_ENV: "wheelinstall-py37"
<<: *ci-steps
Expand All @@ -170,7 +175,7 @@ jobs:

miniconda36:
docker:
- image: continuumio/miniconda3:4.6.14
- image: continuumio/miniconda3:4.7.12
environment:
- CONDA_PYTHON_VER: "3.6"
- TEST_TOX_ENV: "py36"
Expand All @@ -180,7 +185,7 @@ jobs:

miniconda37:
docker:
- image: continuumio/miniconda3:4.6.14
- image: continuumio/miniconda3:4.7.12
environment:
- CONDA_PYTHON_VER: "3.7"
- TEST_TOX_ENV: "py37"
Expand All @@ -204,14 +209,14 @@ jobs:

gallery37:
docker:
- image: dozturk2/python37-hdf5
- image: circleci/python:3.7.6-stretch
environment:
- TEST_TOX_ENV: "gallery-py37"
<<: *gallery-steps

deploy-dev:
docker:
- image: circleci/python:3.7.0-stretch
- image: circleci/python:3.7.6-stretch
steps:
- checkout
- attach_workspace:
Expand All @@ -233,7 +238,7 @@ jobs:
deploy-release:
docker:
- image: circleci/python:3.7.0-stretch
- image: circleci/python:3.7.6-stretch
steps:
- attach_workspace:
at: ./
Expand Down Expand Up @@ -293,6 +298,11 @@ workflows:
- gallery36
- gallery37
filters:
tags:
ignore:
# exclude tags created by "ci_addons publish_github_release"
- /^latest$/
- /^latest-tmp$/
branches:
only: dev
- deploy-release:
Expand Down
18 changes: 10 additions & 8 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,47 +9,47 @@ jobs:
imageName: 'macos-10.13'
pythonVersion: '3.7'
testToxEnv: 'py37'
coverageToxEnv: 'coverage-py37'
coverageToxEnv: 'coverage'
buildToxEnv: 'build-py37'
testWheelInstallEnv: 'wheelinstall-py37'

macOS-py3.6:
imageName: 'macos-10.13'
pythonVersion: '3.6'
testToxEnv: 'py36'
coverageToxEnv: 'coverage-py36'
coverageToxEnv: ''
buildToxEnv: 'build-py36'
testWheelInstallEnv: 'wheelinstall-py36'

macOS-py3.5:
imageName: 'macos-10.13'
pythonVersion: '3.5'
testToxEnv: 'py35'
coverageToxEnv: 'coverage-py35'
coverageToxEnv: ''
buildToxEnv: 'build-py35'
testWheelInstallEnv: 'wheelinstall-py35'

Windows-py3.7:
imageName: 'vs2017-win2016'
pythonVersion: '3.7'
testToxEnv: 'py37'
coverageToxEnv: 'coverage-py37'
coverageToxEnv: 'coverage'
buildToxEnv: 'build-py37'
testWheelInstallEnv: 'wheelinstall-py37'

Windows-py3.6:
imageName: 'vs2017-win2016'
pythonVersion: '3.6'
testToxEnv: 'py36'
coverageToxEnv: 'coverage-py36'
coverageToxEnv: ''
buildToxEnv: 'build-py36'
testWheelInstallEnv: 'wheelinstall-py36'

Windows-py3.5:
imageName: 'vs2017-win2016'
pythonVersion: '3.5'
testToxEnv: 'py35'
coverageToxEnv: 'coverage-py35'
coverageToxEnv: ''
buildToxEnv: 'build-py35'
testWheelInstallEnv: 'wheelinstall-py35'

Expand Down Expand Up @@ -77,8 +77,10 @@ jobs:
displayName: 'Run tox tests'
- bash: |
tox -e $(coverageToxEnv)
displayName: 'Run coverage tests'
if [[ "$(coverageToxEnv)" != "" ]]; then
tox -e $(coverageToxEnv)
fi
displayName: 'Run coverage tests if coverageToxEnv != ""'
- bash: |
tox -e $(buildToxEnv)
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[wheel]
[bdist_wheel]
universal = 1

[versioneer]
Expand Down
17 changes: 2 additions & 15 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -47,26 +47,13 @@ commands = {[testenv:build]commands}

# Envs that will only be executed on CI that does coverage reporting
[testenv:coverage]
passenv = CODECOV_TOKEN
basepython = python3.7
commands =
coverage run test.py --pynwb
coverage report -m
codecov -X fix

[testenv:coverage-py35]
passenv = CODECOV_TOKEN
basepython = python3.5
commands = {[testenv:coverage]commands}

[testenv:coverage-py36]
passenv = CODECOV_TOKEN
basepython = python3.6
commands = {[testenv:coverage]commands}

[testenv:coverage-py37]
passenv = CODECOV_TOKEN
basepython = python3.7
commands = {[testenv:coverage]commands}

# Envs that will test installation from a wheel
[testenv:wheelinstall-py35]
deps = null
Expand Down

0 comments on commit d631fe5

Please sign in to comment.