Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
124 changes: 105 additions & 19 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,18 @@ concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true

defaults:
run:
shell: bash

jobs:
build:
runs-on: ${{ matrix.os }}-latest
strategy:
fail-fast: false
matrix:
os: [ubuntu, macos, windows]
python-version: [ '3.7', '3.8', '3.9', '3.10', 'pypy-3.7' ]
python-version: [ '3.7', '3.8', '3.10', 'pypy-3.7' ]
exclude:
- os: windows
python-version: pypy-3.7
Expand All @@ -29,7 +33,7 @@ jobs:

- name: Install the Python dependencies
run: |
pip install --pre --upgrade --upgrade-strategy=eager .[test] codecov
pip install .[test] codecov

- name: Install matplotlib
if: ${{ matrix.os != 'macos' && matrix.python-version != 'pypy3' }}
Expand All @@ -52,29 +56,24 @@ jobs:
pip check

- name: Run the tests
timeout-minutes: 10
if: ${{ !startsWith( matrix.python-version, 'pypy' ) }}
run: |
pytest ipykernel -vv -s --cov ipykernel --cov-branch --cov-report term-missing:skip-covered --durations 10

- name: Run the tests on pypy
timeout-minutes: 15
if: ${{ startsWith( matrix.python-version, 'pypy' ) }}
if: ${{ !startsWith( matrix.python-version, 'pypy' ) && matrix.os != 'windows' }}
run: |
pytest -vv ipykernel
args="-vv -raXxs --cov ipykernel --cov-branch --cov-report term-missing:skip-covered --durations 10 --color=yes"
pytest $args || pytest $args --lf

- name: Build the docs
if: ${{ matrix.os == 'ubuntu' && matrix.python-version == '3.9'}}
- name: Run the tests on pypy and windows
timeout-minutes: 15
if: ${{ startsWith( matrix.python-version, 'pypy' ) || matrix.os == 'windows' }}
run: |
cd docs
pip install -r requirements.txt
make html
args="-vv -raXxs --durations 10 --color=yes"
pytest $args || pytest $args --lf

- name: Coverage
run: |
codecov

check_docstrings:
test_docs:
runs-on: ${{ matrix.os }}-latest
strategy:
fail-fast: false
Expand All @@ -91,9 +90,16 @@ jobs:
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1

- name: Build the docs
if: ${{ matrix.os == 'ubuntu' && matrix.python-version == '3.9'}}
run: |
cd docs
pip install -r requirements.txt
make html SPHINXOPTS="-W"

- name: Install the Python dependencies
run: |
pip install --pre --upgrade --upgrade-strategy=eager .
pip install .
pip install velin

- name: Check Docstrings
Expand All @@ -116,7 +122,7 @@ jobs:

- name: Install the Python dependencies without debugpy
run: |
pip install --pre --upgrade --upgrade-strategy=eager .[test]
pip install .[test]
pip uninstall --yes debugpy

- name: List installed packages
Expand All @@ -126,4 +132,84 @@ jobs:
- name: Run the tests
timeout-minutes: 10
run: |
pytest ipykernel -vv -s --durations 10
args="-vv -raXxs --durations 10 --color=yes"
pytest $args || pytest $args --lf

test_miniumum_versions:
name: Test Minimum Versions
timeout-minutes: 20
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
with:
python_version: "3.7"
- name: Install miniumum versions
uses: jupyterlab/maintainer-tools/.github/actions/install-minimums@v1
- name: Run the unit tests
run: |
args="-vv -raXxs --durations 10 --color=yes"
pytest $args || pytest $args --lf

test_prereleases:
name: Test Prereleases
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- name: Install the Python dependencies
run: |
pip install --pre -e ".[test]"
- name: List installed packages
run: |
pip freeze
pip check
- name: Run the tests
run: |
args="-vv -raXxs --durations 10 --color=yes"
pytest $args || pytest $args --lf

make_sdist:
name: Make SDist
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- uses: actions/checkout@v2
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- name: Build SDist
run: |
pip install build
python -m build --sdist
- uses: actions/upload-artifact@v2
with:
name: "sdist"
path: dist/*.tar.gz

test_sdist:
runs-on: ubuntu-latest
needs: [make_sdist]
name: Install from SDist and Test
timeout-minutes: 20
steps:
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- name: Download sdist
uses: actions/download-artifact@v2
- name: Install From SDist
run: |
set -ex
cd sdist
mkdir test
tar --strip-components=1 -zxvf *.tar.gz -C ./test
cd test
pip install .[test]
- name: Run Test
run: |
cd sdist/test
args="-vv -raXxs --durations 10 --color=yes"
pytest $args || pytest $args --lf
1 change: 1 addition & 0 deletions .github/workflows/downstream.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ jobs:
uses: jupyterlab/maintainer-tools/.github/actions/downstream-test@v1
with:
package_name: ipyparallel
package_spec: "-e \".[test]\""

jupyter_kernel_test:
runs-on: ubuntu-latest
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def run(self):
'ipython>=7.23.1',
'traitlets>=5.1.0,<6.0',
'jupyter_client<8.0',
'tornado>=4.2,<7.0',
'tornado>=5.0,<7.0',
'matplotlib-inline>=0.1.0,<0.2.0',
'appnope;platform_system=="Darwin"',
'psutil',
Expand Down