@@ -60,10 +60,12 @@ jobs:
6060
6161 - name : Install dependencies
6262 run : |
63- openssl version
6463 python -m pip install --upgrade twisted coverage build
6564
66- - name : Test
65+ - name : Test build on each supported python
66+ run : python -m build .
67+
68+ - name : Test code
6769 run : |
6870 coverage run -m twisted.trial constantly
6971 mv .coverage .coverage.${{ matrix.python-version }}
7577 path : .coverage.*
7678 if-no-files-found : error # 'warn' or 'ignore' are also available.
7779
80+
7881 coverage :
7982 name : Combine & check coverage.
8083 needs : testing
@@ -155,6 +158,10 @@ jobs:
155158 release-publish :
156159 name : Check release and publish on twisted-* tag
157160 runs-on : ' ubuntu-latest'
161+ permissions :
162+ # IMPORTANT: this permission is mandatory for trusted publishing
163+ id-token : write
164+
158165 steps :
159166 - uses : actions/checkout@v3
160167
@@ -163,10 +170,14 @@ jobs:
163170 with :
164171 python-version : ' ${{ env.DEFAULT_PYTHON_VERSION }}'
165172
173+ - name : Install dependencies
174+ run : |
175+ python -m pip install --upgrade build
176+
166177 - name : Build
167178 run : |
168179 rm -rf dist/*
169- pipx run --python=python build .
180+ python -m build .
170181
171182 - name : Files to be pushed to PyPi
172183 run : ls -R dist/
@@ -179,7 +190,7 @@ jobs:
179190
180191 - name : Publish to PyPI - on tag
181192 if : startsWith(github.ref, 'refs/tags/')
182- uses : pypa/gh-action-pypi-publish@a56da0b891b3dc519c7ee3284aff1fad93cc8598
193+ uses : pypa/gh-action-pypi-publish@release/v1
183194
184195
185196 # We have this job so that the PR can be blocked on a single job.
0 commit comments