Skip to content

Commit

Permalink
ci: update to coactions/dynamic-matrix v3 (latest) (#161)
Browse files Browse the repository at this point in the history
* ci: update to `coactions/dynamic-matrix` v3 (latest)

* ci: prefer `matrix.name` as step name instead of command

* pre-commit: remove py3.10 language default constraint

* pyproject.toml: remove language-version constraint from `tomli`

* pyproject.toml: remove global language setting from `mypy` module settings

* Revert "pyproject.toml: remove language-version constraint from `tomli`"

This reverts commit eb47f7a.

* pyproject.toml: add `mypy` import-ignore for `tomli`

* lint: ignore `mypy` redifinition error

---------

Co-authored-by: Sorin Sbarnea <[email protected]>
  • Loading branch information
jayaddison and ssbarnea committed Sep 2, 2024
1 parent 75561eb commit 3aeedab
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 9 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/tox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
steps:
- name: Determine matrix
id: generate_matrix
uses: coactions/matrix@main
uses: coactions/matrix@v3
with:
other_names: |
lint
Expand Down Expand Up @@ -48,8 +48,8 @@ jobs:
python -m pip install --upgrade pip
pip install tox>=4.0
- name: tox run -e ${{ matrix.passed_name }}
run: tox run -e ${{ matrix.passed_name }}
- name: ${{ matrix.name }}
run: ${{ matrix.command }}

check: # This job does nothing and is only used for the branch protection
if: always()
Expand Down
4 changes: 0 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
---
default_language_version:
# Enforce use of py310 because pylint does not support py311 yet, causing
# failures for those happening to have that as default python.
python: python3.10
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0 # Use the ref you want to point at
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,11 @@ filterwarnings = [
]

[[tool.mypy.overrides]]
python_version = "3.8"
module = [
"doc8._version",
"restructuredtext_lint",
"stevedore",
"tomli",
]
ignore_missing_imports = true

Expand Down
2 changes: 1 addition & 1 deletion src/doc8/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
from tomllib import load as toml_load # type: ignore
except ImportError:
# py3.10 or older
from tomli import load as toml_load
from tomli import load as toml_load # type: ignore[no-redef]

from stevedore import extension

Expand Down

0 comments on commit 3aeedab

Please sign in to comment.