From de96c973e557f892d644597d0a272b38a4ddc00b Mon Sep 17 00:00:00 2001 From: Jonas Eschle Date: Tue, 30 Apr 2024 15:25:07 -0400 Subject: [PATCH] chore: upgrade python versions (#70) * ci: upgrade python versions * ci: fix typok * ci: fix typo * ci: fix typo * chore: add ruff to pre-commit * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- .github/workflows/ci.yml | 12 +++++++----- .pre-commit-config.yaml | 12 +++++++++++- setup.cfg | 6 +++--- 3 files changed, 21 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ece0378..5b8da0b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,18 +29,20 @@ jobs: strategy: fail-fast: false matrix: - python-version: [3.7, 3.9] + python-version: ["3.8", "3.12"] runs-on: [ubuntu-latest, macos-13, windows-latest] - include: - - python-version: pypy-3.7 - runs-on: ubuntu-latest + - python-version: "3.12" + runs-on: macos-14 + + + steps: - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 + - uses: actions/setup-python@v4 with: python-version: ${{ matrix.python-version }} diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index adc80f0..8efab1f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -36,7 +36,7 @@ repos: rev: v2.5.0 hooks: - id: setup-cfg-fmt - args: [--include-version-classifiers, --min-py3-version=3.7, --max-py-version=3.11] + args: [--include-version-classifiers, --min-py3-version=3.8, --max-py-version=3.12] - repo: https://github.com/pycqa/flake8 rev: 7.0.0 @@ -56,3 +56,13 @@ repos: hooks: - id: check-manifest stages: [manual] + +- repo: https://github.com/astral-sh/ruff-pre-commit + # Ruff version. + rev: v0.4.1 + hooks: + # Run the linter. + - id: ruff + args: [ --fix ] + # Run the formatter. + - id: ruff-format diff --git a/setup.cfg b/setup.cfg index d4bc491..6007615 100644 --- a/setup.cfg +++ b/setup.cfg @@ -21,16 +21,16 @@ classifiers = Programming Language :: Python Programming Language :: Python :: 3 Programming Language :: Python :: 3 :: Only - Programming Language :: Python :: 3.7 Programming Language :: Python :: 3.8 Programming Language :: Python :: 3.9 Programming Language :: Python :: 3.10 Programming Language :: Python :: 3.11 + Programming Language :: Python :: 3.12 Topic :: Scientific/Engineering [options] packages = find: -python_requires = >=3.7 +python_requires = >=3.8 include_package_data = True package_dir = =src @@ -63,7 +63,7 @@ per-file-ignores = [mypy] files = src -python_version = 3.7 +python_version = 3.8 warn_unused_configs = True disallow_any_generics = True disallow_subclassing_any = True