From 42cafd1de8420917e7abb0a929456776dfaa875f Mon Sep 17 00:00:00 2001 From: Erik-Jan van Kesteren Date: Sat, 24 Feb 2024 14:29:47 +0100 Subject: [PATCH] Move CI to ruff and include 3.12 --- .github/workflows/python-package.yml | 25 +++++++------------------ 1 file changed, 7 insertions(+), 18 deletions(-) diff --git a/.github/workflows/python-package.yml b/.github/workflows/python-package.yml index 6f03a60..372f857 100644 --- a/.github/workflows/python-package.yml +++ b/.github/workflows/python-package.yml @@ -1,6 +1,3 @@ -# This workflow will install Python dependencies, run tests and lint with a variety of Python versions -# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions - name: Python package on: @@ -18,14 +15,9 @@ jobs: strategy: fail-fast: false matrix: - python-version: [3.8, 3.9, "3.10", "3.11"] - metasyn-version: ["metasyn"] - include: - - metasyn-version: "git+https://github.com/sodascience/metasyn.git@main" - python-version: "3.11" - # - metasyn-version: "metasyn==0.6.0" - # python-version: "3.11" - + python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] + metasyn-version: [ "git+https://github.com/sodascience/metasyn.git@main" ] + steps: - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} @@ -36,20 +28,17 @@ jobs: run: | python -m pip install --upgrade pip python -m pip install ${{ matrix.metasyn-version }} - python -m pip install pylint pytest pydocstyle mypy nbval + python -m pip install ruff mypy pytest nbval python -m pip install . - - name: Lint with pylint - run: | - pylint metasyncontrib/disclosure - - name: Check docstrings with pydocstyle + - name: Lint with ruff run: | - pydocstyle metasyncontrib/disclosure --convention=numpy --add-select=D417 --add-ignore="D102,D105,D406" + ruff metasyncontrib/disclosure - name: Check types with MyPy run: | mypy metasyncontrib/disclosure - name: Test with pytest run: | pytest tests - - name: Check notebook output + - name: Check notebook output with pytest run: | pytest --nbval-lax examples