]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
fall back to twine upload without attestations if attestation signing fails
authorMike Bayer <mike_mp@zzzcomputing.com>
Sat, 27 Jun 2026 19:46:41 +0000 (15:46 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Sat, 27 Jun 2026 22:32:39 +0000 (18:32 -0400)
On some platforms (e.g. windows-11-arm) pypi-attestations cannot install
due to missing cryptography binary wheels. Use continue-on-error on the
attestation step and conditionally pass --attestations to twine only when
signing succeeded.

Change-Id: Ibc9b5091c0db361f24376a887d6db04b0e32503c

.github/workflows/create-wheels.yaml

index 708dab5097ecc54b446154511e82f0680b4e59a9..a0ff4ed0e10adff2f8562b61f8495f83cef9e591 100644 (file)
@@ -128,11 +128,18 @@ jobs:
           files: './wheelhouse/*.whl'
 
       - name: Generate attestations
+        id: attestations
+        continue-on-error: true
         run: |
           pip install pypi-attestations
           python -m pypi_attestations sign ./wheelhouse/*
 
       - name: Publish wheel
+        shell: bash
         run: |
           pip install "twine>=6.2.0"
-          twine upload --skip-existing --attestations ./wheelhouse/*
+          if [[ "${{ steps.attestations.outcome }}" == "success" ]]; then
+            twine upload --skip-existing --attestations ./wheelhouse/*
+          else
+            twine upload --skip-existing ./wheelhouse/*
+          fi