potiuk commented on code in PR #77101:
URL: https://github.com/apache/airflow/pull/77101#discussion_r4577206113


##########
.github/workflows/ci-amd.yml:
##########
@@ -42,7 +42,7 @@ on:  # yamllint disable-line rule:truthy
       - chart/v[0-9]+-[0-9]+x-stable
       - airflow-ctl/v[0-9]+-[0-9]+-test
       - airflow-ctl/v[0-9]+-[0-9]+-stable
-    types: [opened, reopened, synchronize, ready_for_review]
+    types: [opened, reopened, synchronize, ready_for_review, labeled]

Review Comment:
   **every label starts a ci-amd.yml run**
   
   GitHub cannot filter a `labeled` trigger by label name, so with this change 
every label added to any pull request, by people and by bots alike, starts a 
`Tests (AMD)` run. The job-level conditions skip most of it, but `ci-passed` 
runs on `if: always()`, so each label still takes a runner to report `CI passed 
(project CI not run)`, and the run, with its skipped job matrix, stays on the 
pull request (the reconciler's cleanup only recognises runs whose gate 
succeeded). We would rather not start any CI run for label changes. Let the 
fork CI monitor start project CI instead, and drop the `labeled` trigger: the 
reconciler already sees `use project ci` within a few minutes when it releases 
the pull request, and at that point it can re-run the pull request's latest 
`ci-amd.yml` run for the head commit (`POST 
/repos/{owner}/{repo}/actions/runs/{run_id}/rerun`). The gate reads the labels 
when it runs, so the re-run goes to project CI. Two things to handle: the 
reconciler deletes gated runs,
  so it would keep the latest gated run of the current head until the pull 
request is released (or there is nothing to re-run), and the re-run is 
requested with `GITHUB_TOKEN`, so please check on a test pull request that it 
starts, as events caused by that token do not start workflows. This also makes 
the `check-ci-workflows-in-sync` failure go away: that check holds the AMD-only 
trigger and gate blocks as literals and currently rejects the new `types` and 
`if:`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to