diff --git a/.github/workflows/pytest-py310.yml b/.github/workflows/pytest-py310.yml index d29c97603..a96fa04d2 100644 --- a/.github/workflows/pytest-py310.yml +++ b/.github/workflows/pytest-py310.yml @@ -16,7 +16,7 @@ jobs: steps: - uses: actions/checkout@v2 - name: Set up Python 3.10 - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: '3.10' - name: Install dependencies diff --git a/.github/workflows/pytest-py311.yml b/.github/workflows/pytest-py311.yml index 7f6443f1b..7bbedcac6 100644 --- a/.github/workflows/pytest-py311.yml +++ b/.github/workflows/pytest-py311.yml @@ -16,7 +16,7 @@ jobs: steps: - uses: actions/checkout@v2 - name: Set up Python 3.11 - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: '3.11' - name: Install dependencies diff --git a/.github/workflows/pytest-py312.yml b/.github/workflows/pytest-py312.yml new file mode 100644 index 000000000..f3896ad79 --- /dev/null +++ b/.github/workflows/pytest-py312.yml @@ -0,0 +1,42 @@ +name: pytest-py312 + +on: + #push: + # branches: [ main ] + #pull_request: + # branches: [ main ] + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + - name: Set up Python 3.12 + uses: actions/setup-python@v4 + with: + python-version: '3.12' + #allow-prereleases: true + - name: Install dependencies + run: | + python -m pip install --upgrade pip setuptools + python -m pip install -r requirements.txt + python -m pip install -r requirements_dev.txt + - name: list env contents + run: | + conda info + conda list + pip list + - name: Lint with flake8 + run: | + # stop the build if there are Python syntax errors or undefined names + flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics + # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide + flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics + - name: Test with pytest + run: | + pytest -m "not requireslocaldata" --cov=dfm_tools --cov-report xml --cov-report term + - uses: codecov/codecov-action@v1 diff --git a/.github/workflows/pytest-py313.yml b/.github/workflows/pytest-py313.yml new file mode 100644 index 000000000..a2f563b43 --- /dev/null +++ b/.github/workflows/pytest-py313.yml @@ -0,0 +1,42 @@ +name: pytest-py313 + +on: + #push: + # branches: [ main ] + #pull_request: + # branches: [ main ] + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + - name: Set up Python 3.13 + uses: actions/setup-python@v4 + with: + python-version: '3.13' + allow-prereleases: true + - name: Install dependencies + run: | + python -m pip install --upgrade pip setuptools + python -m pip install -r requirements.txt + python -m pip install -r requirements_dev.txt + - name: list env contents + run: | + conda info + conda list + pip list + - name: Lint with flake8 + run: | + # stop the build if there are Python syntax errors or undefined names + flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics + # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide + flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics + - name: Test with pytest + run: | + pytest -m "not requireslocaldata" --cov=dfm_tools --cov-report xml --cov-report term + - uses: codecov/codecov-action@v1 diff --git a/.github/workflows/pytest-py38.yml b/.github/workflows/pytest-py38.yml index 2344405af..6ce4bea60 100644 --- a/.github/workflows/pytest-py38.yml +++ b/.github/workflows/pytest-py38.yml @@ -16,7 +16,7 @@ jobs: steps: - uses: actions/checkout@v2 - name: Set up Python 3.8 - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: '3.8' - name: Install dependencies diff --git a/.github/workflows/pytest-py39.yml b/.github/workflows/pytest-py39.yml index 5fda517b5..e9869461a 100644 --- a/.github/workflows/pytest-py39.yml +++ b/.github/workflows/pytest-py39.yml @@ -16,7 +16,7 @@ jobs: steps: - uses: actions/checkout@v2 - name: Set up Python 3.9 - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: '3.9' - name: Install dependencies diff --git a/README.md b/README.md index 1446ed7f0..6975ba8e1 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,7 @@ [![pytest-py39](https://github.com/Deltares/dfm_tools/actions/workflows/pytest-py39.yml/badge.svg?branch=main)](https://github.com/Deltares/dfm_tools/actions/workflows/pytest-py39.yml) [![pytest-py310](https://github.com/Deltares/dfm_tools/actions/workflows/pytest-py310.yml/badge.svg?branch=main)](https://github.com/Deltares/dfm_tools/actions/workflows/pytest-py310.yml) [![pytest-py311](https://github.com/Deltares/dfm_tools/actions/workflows/pytest-py311.yml/badge.svg?branch=main)](https://github.com/Deltares/dfm_tools/actions/workflows/pytest-py311.yml) +[![pytest-py312](https://github.com/Deltares/dfm_tools/actions/workflows/pytest-py312.yml/badge.svg?branch=main)](https://github.com/Deltares/dfm_tools/actions/workflows/pytest-py312.yml) [![codecov](https://img.shields.io/codecov/c/github/deltares/dfm_tools.svg?style=flat-square)](https://app.codecov.io/gh/deltares/dfm_tools?displayType=list) [![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=Deltares_dfm_tools&metric=alert_status)](https://sonarcloud.io/summary/overall?id=Deltares_dfm_tools) [![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/Deltares/dfm_tools/HEAD?urlpath=/tree/docs/notebooks) diff --git a/setup.cfg b/setup.cfg index a1de891a0..05edb08c9 100644 --- a/setup.cfg +++ b/setup.cfg @@ -22,6 +22,7 @@ classifiers = Programming Language :: Python :: 3.9 Programming Language :: Python :: 3.10 Programming Language :: Python :: 3.11 + #python 3.12 is not supported yet: https://github.com/Deltares/dfm_tools/issues/551 [options] python_requires = >=3.8