Skip to content

refactor: clean up imports #635

refactor: clean up imports

refactor: clean up imports #635

Workflow file for this run

name: Lint Python code
on:
pull_request:
branches:
- "main"
- "release-**"
paths-ignore:
- "docs/**"
- "**.md"
- CODEOWNERS
- LICENSE
permissions:
contents: read
# Optional: allow read access to pull request. Use with `only-new-issues` option.
pull-requests: read
# Optional: Allow write access to checks to allow the action to annotate code in the PR.
checks: write
jobs:
code-linter:
name: "Run mypy linting"
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Extract Python version
id: python-version
run: ./scripts/shell/extract-python-version.sh
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: Install Poetry
run: |
curl -sSL https://install.python-poetry.org | python3 -
echo "$HOME/.local/bin" >> $GITHUB_PATH
- name: Install dependencies
run: poetry install --with dev
- name: Run linting
run: poetry run poe lint
- name: Run type checking
run: poetry run poe typecheck
- name: Run code formatting check
run: poetry run poe format