]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.12] Enable the ABI check job to publish the updated ABI data file (GH-105088)
authorSteve Dower <steve.dower@python.org>
Tue, 30 May 2023 16:31:51 +0000 (17:31 +0100)
committerGitHub <noreply@github.com>
Tue, 30 May 2023 16:31:51 +0000 (17:31 +0100)
.github/workflows/build.yml

index 3ada845c4cbbc3de7cbe143a0c1f4e49dbe56ef7..046c2aaa55f67b18e9db861afa26089a51ba0f23 100644 (file)
@@ -100,15 +100,28 @@ jobs:
           ./configure --enable-shared
           make -j4
       - name: Check for changes in the ABI
+        id: check
         run: |
           if ! make check-abidump; then
             echo "Generated ABI file is not up to date."
             echo "Please add the release manager of this branch as a reviewer of this PR."
             echo ""
+            echo "The up to date ABI file should be attached to this build as an artifact."
+            echo ""
             echo "To learn more about this check: https://devguide.python.org/setup/#regenerate-the-abi-dump"
             echo ""
             exit 1
           fi
+      - name: Generate updated ABI files
+        if: ${{ failure() && steps.check.conclusion == 'failure' }}
+        run: |
+          make regen-abidump
+      - uses: actions/upload-artifact@v3
+        name: Publish updated ABI files
+        if: ${{ failure() && steps.check.conclusion == 'failure' }}
+        with:
+          name: abi-data
+          path: ./Doc/data/*.abi
 
   check_generated_files:
     name: 'Check if generated files are up to date'