CI: Type checking: mypy #16
Workflow file for this run
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
# Workflow to run mypy | |
# Adapted from the CPython mypy action | |
name: mypy | |
on: [push, pull_request] | |
permissions: | |
contents: read | |
env: | |
UV_SYSTEM_PYTHON: 1 | |
PIP_DISABLE_PIP_VERSION_CHECK: 1 | |
FORCE_COLOR: 1 | |
TERM: xterm-256color # needed for FORCE_COLOR to work on mypy on Ubuntu, see https://github.com/python/mypy/issues/13817 | |
jobs: | |
mypy: | |
name: mypy | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
with: | |
persist-credentials: false | |
- uses: astral-sh/setup-uv@22695119d769bdb6f7032ad67b9bca0ef8c4a174 # v5.4.0 | |
with: | |
enable-cache: true | |
cache-dependency-glob: '' | |
cache-suffix: '3.13' | |
- name: Setup Python | |
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0 | |
with: | |
python-version: '3.13' | |
- run: sudo apt-get install -y libwayland-dev libcairo2-dev libgirepository-2.0-dev | |
- run: uv pip install -r pyproject.toml | |
- run: uv pip install --group types | |
- run: mypy safeeyes |