From b73cd255c0185edd87d95cf9d34df9a26bbb80d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Robert?= Date: Wed, 23 Jun 2021 20:11:16 +0200 Subject: [PATCH] CI: add a scheduled CI job with bleeding edge versions of Python, matplotlib and numpy --- .github/workflows/bleeding-edge.yaml | 54 ++++++++++++++++++++++++ .github/workflows/build-test-pytest.yaml | 9 +++- .github/workflows/build-test.yaml | 9 +++- README.md | 1 + tests/windows_conda_requirements.txt | 2 +- 5 files changed, 72 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/bleeding-edge.yaml diff --git a/.github/workflows/bleeding-edge.yaml b/.github/workflows/bleeding-edge.yaml new file mode 100644 index 00000000000..dae94349cd8 --- /dev/null +++ b/.github/workflows/bleeding-edge.yaml @@ -0,0 +1,54 @@ +name: CI (bleeding edge) +# this workflow is heavily inspired from pandas, see +# https://github.com/pandas-dev/pandas/blob/master/.github/workflows/python-dev.yml + +# goals: check stability against +# - dev version of Python, numpy, and matplotlib +# - building with future pip default options + +on: + push: + branches: + - main + schedule: + # run this every day at 3 am UTC + - cron: '0 3 * * *' + +jobs: + build: + runs-on: ubuntu-latest + name: Python3.10-dev + timeout-minutes: 60 + + concurrency: + group: ${{ github.ref }}-dev + cancel-in-progress: true + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + + - name: Set up Python Dev Version + uses: actions/setup-python@v2 + with: + python-version: '3.10-dev' + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install --upgrade setuptools wheel + python -m pip install git+https://github.com/numpy/numpy.git + python -m pip install git+https://github.com/matplotlib/matplotlib.git + python -m pip install cython + + - name: Build yt + # --no-build-isolation is used to guarantee that build time dependencies + # are not installed by pip as specified from pyproject.toml, hence we get + # to use the dev version of numpy at build time. + run: | + python setup.py build_ext -q -j2 + python -m pip install -e .[test] --no-build-isolation + + - name: Run Tests + run: pytest -vvv diff --git a/.github/workflows/build-test-pytest.yaml b/.github/workflows/build-test-pytest.yaml index 9010f3d1a4b..aec0faf5cea 100644 --- a/.github/workflows/build-test-pytest.yaml +++ b/.github/workflows/build-test-pytest.yaml @@ -1,6 +1,13 @@ name: Build and Test -on: [push, pull_request] +on: + push: + branches: + - main + pull_request: + paths-ignore: + - "doc/**" + - README.md defaults: run: diff --git a/.github/workflows/build-test.yaml b/.github/workflows/build-test.yaml index 78dec91aab3..1df27b9795e 100644 --- a/.github/workflows/build-test.yaml +++ b/.github/workflows/build-test.yaml @@ -1,6 +1,13 @@ name: Build and Test -on: [push, pull_request] +on: + push: + branches: + - main + pull_request: + paths-ignore: + - "doc/**" + - README.md defaults: run: diff --git a/README.md b/README.md index a2c26e2a452..4c3a4efd182 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,7 @@ ![Build and Test](https://github.com/yt-project/yt/workflows/Build%20and%20Test/badge.svg?branch=main) +[![CI (bleeding edge)](https://github.com/yt-project/yt/actions/workflows/bleeding-edge.yaml/badge.svg)](https://github.com/yt-project/yt/actions/workflows/bleeding-edge.yaml) [![pre-commit.ci status](https://results.pre-commit.ci/badge/github/yt-project/yt/main.svg)](https://results.pre-commit.ci/latest/github/yt-project/yt/main) [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black) [![Imports: isort](https://img.shields.io/badge/%20imports-isort-%231674b1?style=flat&labelColor=ef8336)](https://pycqa.github.io/isort/) diff --git a/tests/windows_conda_requirements.txt b/tests/windows_conda_requirements.txt index ed170b804ce..ac2465128d2 100644 --- a/tests/windows_conda_requirements.txt +++ b/tests/windows_conda_requirements.txt @@ -2,5 +2,5 @@ numpy>=1.19.4 cython>=0.29.21,<3.0 cartopy~=0.18.0 h5py~=3.1.0 -matplotlib<3.6 +matplotlib>=2.0.2,<3.6 scipy~=1.5.0