Skip to content

Commit 16bcdb9

Browse files
committed
ci: reduce API burden and stop using a PAT in trusted workflows
1 parent 9238af8 commit 16bcdb9

1 file changed

Lines changed: 11 additions & 3 deletions

File tree

.github/workflows/tests.yaml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,15 @@ on:
88
- "v*"
99
workflow_dispatch:
1010

11+
permissions:
12+
contents: read
13+
issues: read
14+
pull-requests: read
15+
16+
concurrency:
17+
group: ${{ github.workflow }}-${{ github.ref }}
18+
cancel-in-progress: true
19+
1120
jobs:
1221
pre-commit:
1322
runs-on: ubuntu-24.04
@@ -35,10 +44,9 @@ jobs:
3544
tests:
3645
runs-on: ubuntu-24.04
3746
env:
38-
# Use TOKEN_READONLY if available (pushed branches), otherwise use GITHUB_TOKEN (PRs)
39-
# TOKEN_READONLY is a PAT for @choldgraf that only has read-access to this repo but isn't available in PRs.
40-
GITHUB_ACCESS_TOKEN: "${{ secrets.TOKEN_READONLY || github.token }}"
47+
GITHUB_ACCESS_TOKEN: "${{ github.token }}"
4148
strategy:
49+
max-parallel: 1
4250
matrix:
4351
include:
4452
# Only test oldest supported and latest python version to reduce

0 commit comments

Comments
 (0)