[llvm-branch-commits] [llvm] release/22.x: [CI] Make premerge jobs support GHA postcommit (#176180) (PR #176196)

via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Thu Jan 15 08:25:27 PST 2026


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-infrastructure

Author: None (llvmbot)

<details>
<summary>Changes</summary>

Backport 5acb608b5265b37b2c5dbd5a1699c3d129935d95

Requested by: @<!-- -->boomanaiden154

---
Full diff: https://github.com/llvm/llvm-project/pull/176196.diff


1 Files Affected:

- (modified) .ci/utils.sh (+9-5) 


``````````diff
diff --git a/.ci/utils.sh b/.ci/utils.sh
index 923c64a4e169c..f14fe753415ce 100644
--- a/.ci/utils.sh
+++ b/.ci/utils.sh
@@ -37,11 +37,15 @@ function at-exit {
     python "${MONOREPO_ROOT}"/.ci/generate_test_report_github.py \
       $retcode "${BUILD_DIR}"/test-results.*.xml "${MONOREPO_ROOT}"/ninja*.log \
       >> $GITHUB_STEP_SUMMARY
-    (python "${MONOREPO_ROOT}"/.ci/premerge_advisor_explain.py \
-      $(git rev-parse HEAD~1) $retcode "${GITHUB_TOKEN}" \
-      $GITHUB_PR_NUMBER "${BUILD_DIR}"/test-results.*.xml \
-      "${MONOREPO_ROOT}"/ninja*.log)
-    advisor_retcode=$?
+    if [[ -n "$GITHUB_PR_NUMBER" ]]; then
+      (python "${MONOREPO_ROOT}"/.ci/premerge_advisor_explain.py \
+        $(git rev-parse HEAD~1) $retcode "${GITHUB_TOKEN}" \
+        $GITHUB_PR_NUMBER "${BUILD_DIR}"/test-results.*.xml \
+        "${MONOREPO_ROOT}"/ninja*.log)
+      advisor_retcode=$?
+    else
+      advisor_retcode=$retcode
+    fi
   fi
 
   if [[ "$retcode" != "0" ]]; then

``````````

</details>


https://github.com/llvm/llvm-project/pull/176196


More information about the llvm-branch-commits mailing list