Skip to content

not fallback to get request on 405 only #80

not fallback to get request on 405 only

not fallback to get request on 405 only #80

name: Run Python type, lint and format checks
on:
workflow_dispatch:
push:
branches: [ main, dev ]
paths:
- '**.py'
- ".github/workflows/python-types-lint-format.yaml"
pull_request:
branches: [ main, dev ]
paths:
- '**.py'
- ".github/workflows/python-types-lint-format.yaml"
permissions:
contents: read
jobs:
python-type-check:
if: ${{ always() }} # Always run even if a matrix candidate fails
name: Python ${{ matrix.python_version }} - Check Type - ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
python_version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python_version }}
architecture: x64
- name: Install dependencies
run: |
python3 -m pip install --upgrade pip
python3 -m pip install -e '.[dev]'
- name: Run type check
run: python3 -m mypy .
python-lint-format-check:
if: ${{ always() }} # Always run even if a matrix candidate fails
name: Python ${{ matrix.python_version }} - Check Linting and Formatting - ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
python_version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python_version }}
architecture: x64
- name: Install dependencies
run: |
python3 -m pip install --upgrade pip
python3 -m pip install -e '.[lint]'
- name: Run lint check
run: python3 -m ruff check .
- name: Run format check
run: python3 -m ruff format . --check