From 975a3156958460e8a11b5e0c0f00e587d8e357ec Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Wed, 29 Dec 2021 11:00:56 -0600 Subject: [PATCH 1/7] try against jupyter kernel test --- .github/workflows/check-release.yml | 34 ++--------------------------- .github/workflows/downstream.yml | 11 +++++++++- .github/workflows/main.yml | 31 +++----------------------- 3 files changed, 15 insertions(+), 61 deletions(-) diff --git a/.github/workflows/check-release.yml b/.github/workflows/check-release.yml index 59f48f4b5..44c8f6ca1 100644 --- a/.github/workflows/check-release.yml +++ b/.github/workflows/check-release.yml @@ -17,38 +17,8 @@ jobs: steps: - name: Checkout uses: actions/checkout@v2 - - name: Install Python - uses: actions/setup-python@v2 - with: - python-version: 3.9 - architecture: "x64" - - name: Install node - uses: actions/setup-node@v2 - with: - node-version: "14.x" - - name: Get pip cache dir - id: pip-cache - run: | - echo "::set-output name=dir::$(pip cache dir)" - - name: Cache pip - uses: actions/cache@v1 - with: - path: ${{ steps.pip-cache.outputs.dir }} - key: ${{ runner.os }}-pip-${{ hashFiles('setup.cfg') }} - restore-keys: | - ${{ runner.os }}-pip- - ${{ runner.os }}-pip- - - name: Cache checked links - if: ${{ matrix.group == 'link_check' }} - uses: actions/cache@v2 - with: - path: ~/.cache/pytest-link-check - key: ${{ runner.os }}-linkcheck-${{ hashFiles('**/*.md', '**/*.rst') }}-md-links - restore-keys: | - ${{ runner.os }}-linkcheck- - - name: Upgrade packaging dependencies - run: | - pip install --upgrade pip setuptools wheel --user + - name: Base Setup + uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1 - name: Install Dependencies run: | pip install -e . diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index d734d61f4..da5067f2d 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -45,9 +45,18 @@ jobs: with: package_name: jupyter_server + - name: Setup conda ${{ matrix.python-version }} + uses: conda-incubator/setup-miniconda@v2 + with: + auto-update-conda: true + activate-environment: jupyter_kernel_test + python-version: ${{ matrix.python-version }} + - name: Test jupyter_kernel_test + shell: bash -l {0} run: | git clone https://github.com/jupyter/jupyter_kernel_test.git cd jupyter_kernel_test + conda env update --name jupyter_kernel_test --file environment.yml pip install -e ".[test]" - python test_ipykernel.py + python -m unittest -v diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index fb1437f99..acc50cac9 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -69,7 +69,7 @@ jobs: fail-fast: false matrix: os: [ubuntu-latest, macos-latest, windows-latest] - python-version: [3.6, 3.7, 3.8, 3.9] + python-version: [3.6, 3.7, 3.8, 3.9, "3.10", "pypy-3.7"] env: OS: ${{ matrix.os }} @@ -78,33 +78,8 @@ jobs: - name: Checkout uses: actions/checkout@v2 - - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v2 - with: - python-version: ${{ matrix.python-version }} - - - name: Update pip - run: | - pip install --upgrade pip - pip install --upgrade wheel setuptools - - - name: Get pip cache dir - id: pip-cache - run: | - echo "::set-output name=dir::$(pip cache dir)" - - - name: Cache pip - uses: actions/cache@v2 - with: - path: | - ${{ steps.pip-cache.outputs.dir }} - .mypy_cache - key: ${{ runner.os }}-python-${{ matrix.python-version }}-pip-${{ hashFiles('**/requirements*.txt') }}-git-${{ github.sha }} - restore-keys: | - ${{ runner.os }}-python-${{ matrix.python-version }}-pip-${{ hashFiles('**/requirements*.txt') }} - ${{ runner.os }}-python-${{ matrix.python-version }}-pip- - ${{ runner.os }}-python - ${{ runner.os }}- + - name: Base Setup + uses: jupyterlab/maintainer-tools/.github/base-setup@v1 - name: Install dependencies run: | From 7433762deb4ac357c9cae385e4f0279823773560 Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Wed, 29 Dec 2021 11:31:05 -0600 Subject: [PATCH 2/7] cleanup --- .github/workflows/main.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index acc50cac9..0d8a17088 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -79,7 +79,7 @@ jobs: uses: actions/checkout@v2 - name: Base Setup - uses: jupyterlab/maintainer-tools/.github/base-setup@v1 + uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1 - name: Install dependencies run: | @@ -89,9 +89,14 @@ jobs: - name: Check types run: mypy jupyter_client --exclude '\/tests|kernelspecapp|ioloop|runapp' --install-types --non-interactive - - name: Run the tests + - name: Run the tests with coverage + if: ${{ !startsWith(matrix.python-version, 'pypy') }} run: pytest --cov jupyter_client -v jupyter_client + - name: Run the tests on pypy + if: startsWith(matrix.python-version, 'pypy') + run: pytest -v jupyter_client + - name: Build the docs run: | pip install -r requirements-doc.txt From 24e8fd4ede3672fc5a40e7c2a299e49cf88c5fd5 Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Wed, 29 Dec 2021 11:41:48 -0600 Subject: [PATCH 3/7] remove pypy support --- .github/workflows/main.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 0d8a17088..bffd1a48e 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -69,7 +69,7 @@ jobs: fail-fast: false matrix: os: [ubuntu-latest, macos-latest, windows-latest] - python-version: [3.6, 3.7, 3.8, 3.9, "3.10", "pypy-3.7"] + python-version: [3.6, 3.7, 3.8, 3.9, "3.10"] env: OS: ${{ matrix.os }} @@ -90,13 +90,8 @@ jobs: run: mypy jupyter_client --exclude '\/tests|kernelspecapp|ioloop|runapp' --install-types --non-interactive - name: Run the tests with coverage - if: ${{ !startsWith(matrix.python-version, 'pypy') }} run: pytest --cov jupyter_client -v jupyter_client - - name: Run the tests on pypy - if: startsWith(matrix.python-version, 'pypy') - run: pytest -v jupyter_client - - name: Build the docs run: | pip install -r requirements-doc.txt From e798814471265b2cdb581f4a84d1c2d103c5a711 Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Wed, 29 Dec 2021 22:47:18 -0600 Subject: [PATCH 4/7] add cling test --- .github/workflows/downstream.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index da5067f2d..b19da425e 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -45,6 +45,8 @@ jobs: with: package_name: jupyter_server + # Test using jupyter_kernel_test + - name: Setup conda ${{ matrix.python-version }} uses: conda-incubator/setup-miniconda@v2 with: @@ -58,5 +60,6 @@ jobs: git clone https://github.com/jupyter/jupyter_kernel_test.git cd jupyter_kernel_test conda env update --name jupyter_kernel_test --file environment.yml + conda install -c conda-forge xeus-cling pip install -e ".[test]" python -m unittest -v From 341d333a724f5490fd049b2011d4b017c5b96e0c Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Thu, 30 Dec 2021 10:11:15 -0600 Subject: [PATCH 5/7] specify python version --- .github/workflows/downstream.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index b19da425e..ce0ae9517 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -9,6 +9,9 @@ on: jobs: tests: runs-on: ubuntu-latest + strategy: + matrix: + python-version: "3.9" steps: - name: Checkout From 5234037babd31f894f16be5600200152815c5a71 Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Thu, 30 Dec 2021 10:22:43 -0600 Subject: [PATCH 6/7] fix syntax --- .github/workflows/downstream.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index ce0ae9517..1df08a2d1 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: "3.9" + python-version: ["3.9"] steps: - name: Checkout From 527a3e37d83186cf1c3da97a3b2e9fb43527e73b Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Thu, 30 Dec 2021 11:09:00 -0600 Subject: [PATCH 7/7] try with mambaforge --- .github/workflows/downstream.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index 1df08a2d1..53fd620c6 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -55,6 +55,7 @@ jobs: with: auto-update-conda: true activate-environment: jupyter_kernel_test + miniforge-variant: Mambaforge python-version: ${{ matrix.python-version }} - name: Test jupyter_kernel_test