Skip to content

Task

Task #16

Workflow file for this run

name: Lint
on:
pull_request:
branches: ["**"]
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Set up Github Workspace
uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v5
with:
version: latest
python-version: 3.11
- name: Install Task
uses: arduino/setup-task@v2
- name: Install Python Dependencies
run: task install
- name: Lint
id: lint
continue-on-error: true
run: |
echo "::add-matcher::.github/workflows/matchers/flake8.json"
task lint
echo "::remove-matcher owner=flake8::"
- name: Type Checking
id: check
continue-on-error: true
run: |
echo "::add-matcher::.github/workflows/matchers/mypy.json"
task check
echo "::remove-matcher owner=mypy::"
- name: Raise Errors For Linting Failures
if: |
steps.lint.outcome != 'success' ||
steps.check.outcome != 'success'
run: |
echo "Lint: ${{ steps.lint.outcome }}"
echo "Check: ${{ steps.check.outcome }}"
exit 1