Debian Codegraph @

.github/workflows/lint.yml

raw
1 name: Lint
2
3 permissions:
4 contents: read
5
6 concurrency:
7 group: lint-${{ github.event.pull_request.number || github.ref }}
8 cancel-in-progress: true
9
10 on:
11 push:
12 tags-ignore:
13 - "*"
14 branches:
15 - "*"
16 pull_request:
17 workflow_call:
18 workflow_dispatch:
19 inputs:
20 debug:
21 description: "Open ssh debug session."
22 required: true
23 default: false
24 type: boolean
25
26 jobs:
27 lint:
28 name: Run Static Analysis
29 runs-on: ubuntu-latest
30 permissions:
31 contents: read
32 strategy:
33 fail-fast: false
34 matrix:
35 # run static analysis on bleeding and trailing edges
36 python-version: ["3.10", "3.12", "3.14"]
37 django-version:
38 - "dj42" # LTS April 2026
39 - "dj52" # LTS April 2028
40 - "dj61" #
41 exclude:
42 - python-version: "3.12"
43 django-version: "dj42"
44 - python-version: "3.14"
45 django-version: "dj42"
46
47 - python-version: "3.10"
48 django-version: "dj52"
49 - python-version: "3.14"
50 django-version: "dj52"
51
52 - python-version: "3.10"
53 django-version: "dj61"
54 - python-version: "3.12"
55 django-version: "dj61"
56
57 env:
58 TEST_PYTHON_VERSION: ${{ matrix.python-version }}
59 TEST_DJANGO_VERSION: ${{ matrix.django-version }}
60
61 steps:
62 - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0
63 with:
64 persist-credentials: false
65 - name: Set up Python ${{ matrix.python-version }}
66 uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1
67 id: sp
68 with:
69 python-version: ${{ matrix.python-version }}
70 allow-prereleases: true
71 - name: Install uv
72 uses: astral-sh/setup-uv@fac544c07dec837d0ccb6301d7b5580bf5edae39
73 with:
74 enable-cache: false
75 - name: Install Just
76 uses: extractions/setup-just@53165ef7e734c5c07cb06b3c8e7b647c5aa16db3
77 - name: Install Emacs
78 if: ${{ github.event.inputs.debug == 'true' }}
79 run: |
80 sudo apt install emacs
81 - name: Setup tmate session
82 if: ${{ github.event.inputs.debug == 'true' }}
83 uses: mxschmitt/action-tmate@35b54afac29c97fb54faba5b513f8fbd1882f113
84 timeout-minutes: 60
85 - name: Run Static Analysis
86 env:
87 PYTHON_PATH: ${{ steps.sp.outputs.python-path }}
88 run: |
89 just check -p "$PYTHON_PATH" --group "$TEST_DJANGO_VERSION"