File tree Expand file tree Collapse file tree 8 files changed +42
-17
lines changed Expand file tree Collapse file tree 8 files changed +42
-17
lines changed Original file line number Diff line number Diff line change 55 branches : [main, master, 'release*']
66 tags : ['*']
77
8- permissions :
9- contents : write
10-
118jobs :
129 build-wheels :
1310 if : github.repository == 'python/mypy'
1411 runs-on : ubuntu-latest
12+ permissions :
13+ contents : write
1514 steps :
1615 - uses : actions/checkout@v4
16+ with :
17+ persist-credentials : false
1718 - uses : actions/setup-python@v5
1819 with :
1920 python-version : ' 3.11'
Original file line number Diff line number Diff line change 3535 VERIFY_MYPY_ERROR_CODES : 1
3636 steps :
3737 - uses : actions/checkout@v4
38+ with :
39+ persist-credentials : false
3840 - uses : actions/setup-python@v5
3941 with :
4042 python-version : ' 3.12'
Original file line number Diff line number Diff line change 3838 with :
3939 path : mypy_to_test
4040 fetch-depth : 0
41+ persist-credentials : false
4142 - uses : actions/setup-python@v5
4243 with :
4344 python-version : " 3.12"
@@ -102,3 +103,7 @@ jobs:
102103 name : mypy_primer_diffs
103104 pattern : mypy_primer_diffs-*
104105 delete-merged : true
106+ - name : Call comments workflow
107+ uses : python/mypy/.github/workflows/mypy_primer_comment.yml@master
108+ with :
109+ workflow_id : ${{ workflow.id }}
Original file line number Diff line number Diff line change 11name : Comment with mypy_primer diff
22
33on :
4- workflow_run :
5- workflows :
6- - Run mypy_primer
7- types :
8- - completed
4+ workflow_call :
5+ input :
6+ workflow_id :
7+ required : true
8+ type : integer
99
10- permissions :
11- contents : read
12- pull-requests : write
1310
1411jobs :
1512 comment :
1613 name : Comment PR from mypy_primer
1714 runs-on : ubuntu-latest
18- if : ${{ github.event.workflow_run.conclusion == 'success' }}
15+ permissions :
16+ contents : read
17+ pull-requests : write
1918 steps :
2019 - name : Download diffs
2120 uses : actions/github-script@v7
21+ env :
22+ WORKFLOW_ID : ${{ inputs.workflow_id }}
2223 with :
2324 script : |
2425 const fs = require('fs');
2526 const artifacts = await github.rest.actions.listWorkflowRunArtifacts({
2627 owner: context.repo.owner,
2728 repo: context.repo.repo,
28- run_id: ${{ github.event.workflow_run.id }} ,
29+ run_id: process.env.WORKFLOW_ID ,
2930 });
3031 const [matchArtifact] = artifacts.data.artifacts.filter((artifact) =>
3132 artifact.name == "mypy_primer_diffs");
Original file line number Diff line number Diff line change 55 schedule :
66 - cron : " 0 0 1,15 * *"
77
8- permissions :
9- contents : write
10- pull-requests : write
11-
128jobs :
139 sync_typeshed :
1410 name : Sync typeshed
1511 if : github.repository == 'python/mypy'
1612 runs-on : ubuntu-latest
13+ permissions :
14+ contents : write
15+ pull-requests : write
1716 timeout-minutes : 10
1817 steps :
1918 - uses : actions/checkout@v4
2019 with :
2120 fetch-depth : 0
21+ persist-credentials : false
2222 # TODO: use whatever solution ends up working for
2323 # https://github.com/python/typeshed/issues/8434
2424 - uses : actions/setup-python@v5
Original file line number Diff line number Diff line change @@ -136,6 +136,8 @@ jobs:
136136
137137 steps :
138138 - uses : actions/checkout@v4
139+ with :
140+ persist-credentials : false
139141
140142 - name : Debug build
141143 if : ${{ matrix.debug_build }}
@@ -217,6 +219,8 @@ jobs:
217219 CC : i686-linux-gnu-gcc
218220 steps :
219221 - uses : actions/checkout@v4
222+ with :
223+ persist-credentials : false
220224 - name : Install 32-bit build dependencies
221225 run : |
222226 sudo dpkg --add-architecture i386 && \
Original file line number Diff line number Diff line change 2929 steps :
3030
3131 - uses : actions/checkout@v4
32+ with :
33+ persist-credentials : false
3234
3335 - name : Setup 🐍 3.9
3436 uses : actions/setup-python@v5
Original file line number Diff line number Diff line change @@ -29,5 +29,15 @@ repos:
2929 -ignore=property "allow_failure" is not defined,
3030 -ignore=SC2(046|086),
3131 ]
32+ - repo : https://github.com/woodruffw/zizmor-pre-commit
33+ rev : v1.0.0
34+ hooks :
35+ - id : zizmor
36+ # Should be the last one:
37+ - repo : meta
38+ hooks :
39+ - id : check-hooks-apply
40+ - id : check-useless-excludes
41+
3242ci :
3343 autoupdate_schedule : quarterly
You can’t perform that action at this time.
0 commit comments