Fix pillow type stubs #363
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run tools | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
workflow_dispatch: | |
# Allow triggering manually on other branches. | |
permissions: | |
contents: read | |
pull-requests: read | |
# This is for non-version-specific checks. | |
jobs: | |
run-tools: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- name: Set up Python 3.13 | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.13' | |
cache: 'pip' | |
cache-dependency-path: | | |
test-requirements.txt | |
tool-requirements.txt | |
pyproject.toml | |
- name: Read project dependencies | |
run: | | |
python .github/workflows/read_deps.py | |
- name: Install dependencies | |
id: install_deps | |
run: | | |
python -m pip install --upgrade pip setuptools wheel | |
python -m pip install -r pyproject-deps.txt -r tool-requirements.txt | |
mypy --version | |
- name: Lint with Ruff | |
run: | | |
ruff check src/srctools/ | |
# Override regular check, to run all tools even if one fails. | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' | |
# Check every version. | |
- name: MyPy - Python 3.9 | |
run: | | |
mypy --python-version 3.9 src/srctools/ type_tests/ | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' | |
- name: MyPy - Python 3.10 | |
run: | | |
mypy --python-version 3.10 src/srctools/ type_tests/ | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' | |
- name: MyPy - Python 3.11 | |
run: | | |
mypy --python-version 3.11 src/srctools/ type_tests/ | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' | |
- name: MyPy - Python 3.12 | |
run: | | |
mypy --python-version 3.12 src/srctools/ type_tests/ | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' | |
- name: MyPy - Python 3.13 | |
run: | | |
mypy --python-version 3.13 src/srctools/ type_tests/ | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' | |
- name: Pyright - Python 3.9 | |
run: | | |
pyright --pythonversion 3.9 | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' | |
- name: Pyright - Python 3.10 | |
run: | | |
pyright --pythonversion 3.10 | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' | |
- name: Pyright - Python 3.11 | |
run: | | |
pyright --pythonversion 3.11 | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' | |
- name: Pyright - Python 3.12 | |
run: | | |
pyright --pythonversion 3.12 | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' | |
- name: Pyright - Python 3.13 | |
run: | | |
pyright --pythonversion 3.13 | |
if: (success() || failure()) && steps.install_deps.outcome == 'success' |