https://github.com/llvmbot created https://github.com/llvm/llvm-project/pull/176196
Backport 5acb608b5265b37b2c5dbd5a1699c3d129935d95 Requested by: @boomanaiden154 >From f6de3be2ae6e9aeb33c46e6b96ae7ded60e194d2 Mon Sep 17 00:00:00 2001 From: Aiden Grossman <[email protected]> Date: Thu, 15 Jan 2026 08:16:39 -0800 Subject: [PATCH] [CI] Make premerge jobs support GHA postcommit (#176180) This was causing failures in the release branch as the premerge jobs there are also run postcommit through GHA. We were expecting a PR number to always be present when it was not. (cherry picked from commit 5acb608b5265b37b2c5dbd5a1699c3d129935d95) --- .ci/utils.sh | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) 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 _______________________________________________ llvm-branch-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits
