[llvm] [Github][RFC] Add workflow to diff codegen on llvm-test-suite (PR #190010)

Luke Lau via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 7 06:48:12 PDT 2026


================
@@ -22,7 +23,8 @@ jobs:
     permissions:
       pull-requests: write
     if: >
-      github.event.workflow_run.event == 'pull_request' &&
+      (github.event.workflow_run.event == 'pull_request' ||
+       github.event.workflow_run.event == 'issue_comment') &&
----------------
lukel97 wrote:

Was meaning to give an explanation for this but was just waiting for a test run to finish. 

It turns out that on `issue_comment` workflows, the head branch which is used to fetch the PR number below is actually set to the default branch (main), not the branch of the PR that was commented on. So the issue workflow fails.

To fix that it looks like we have to manually plumb the PR number through an artefact: https://docs.github.com/en/actions/reference/workflows-and-actions/events-that-trigger-workflows#using-data-from-the-triggering-workflow

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


More information about the llvm-commits mailing list