ci: the needs-rebase labeler no longer runs per pull request push (PR-CONFLICT-LABEL-LOAD) #1250

Merged
Mouad-Scriptz-0 merged 1 commit from upstream-pr/1250 into main 2026-11-24 20:59:24 +00:00
Mouad-Scriptz-0 commented 2026-11-24 20:52:04 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by Mouad-Scriptz-0 on 2026-11-24T20:52:04Z.


Claimed in the coordination issue as: PR-CONFLICT-LABEL-LOAD (#14)

Depends on: none

What and why

My needs rebase labeler from #155 works (112 open pull requests carry the label), but it's flooding the Actions queue. conflict-label.yml starts a run on every push to every pull request through pull_request_target. On this repository, that queued about 265 runs within a day, the oldest since 15:27 UTC. They wait in the same runner queue as CI (53 queued, the oldest since 14:41 UTC), No Game Data (59) and Runtime (29). I'm sorry about that.

This PR:

  • Drops the pull_request_target trigger. Every run already checks all open pull requests, so the push-to-main and hourly runs cover what the per-PR runs did. A rebased pull request now loses the label within the hour instead of right away.
  • Puts every run in one concurrency group (conflict-label). At most one run is in progress and one waiting, and a newer push replaces the waiting one.
  • Removes the per-PR --pr argument from the workflow. The workflow also no longer has a trigger that gives a fork's pull request a write token.
  • Updates tests/test_pr_conflict_label.py. It now checks that no pull_request / pull_request_target trigger, per-PR group or --pr comes back. The tool's docstring and the CONTRIBUTING.md line describe the new schedule.

Runs that are already queued will still run under the old workflow file. Each one is harmless but holds a runner slot. Someone with write access can clear them; the next push to main, or the hourly run, re-labels everything:

for s in queued pending; do
  gh run list -R ubiquitarianism/leonida --workflow conflict-label.yml --status "$s" --limit 1000 \
    --json databaseId --jq '.[].databaseId' | xargs -r -n1 gh run cancel -R ubiquitarianism/leonida
done

Tested

  • tests/test_pr_conflict_label.py: OK. Against the workflow on main (the old triggers), the new test_no_run_per_pull_request fails, as it should.
  • tests/test_ci_registration.py, tests/test_docs_links.py, tests/test_text_write_line_endings.py: OK.
  • The workflow YAML parses: triggers push, schedule and workflow_dispatch; concurrency {group: conflict-label, cancel-in-progress: false}.

GPUs tested: n/a (CI only)

AI-assisted: yes (Claude Code)

Checklist

  • Based on current main and merges cleanly (a conflicting pull request is labeled needs rebase).
  • One topic; follow-up work goes in a new pull request.
  • No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here.
  • A new translator rule is in the contract table of docs/design.md, with how it was confirmed. (n/a)
<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5480126324 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/1250). Originally posted by [Mouad-Scriptz-0](https://github.com/Mouad-Scriptz-0) on 2026-11-24T20:52:04Z. --- Claimed in the coordination issue as: PR-CONFLICT-LABEL-LOAD (#14) Depends on: none ### What and why My `needs rebase` labeler from #155 works (112 open pull requests carry the label), but it's flooding the Actions queue. `conflict-label.yml` starts a run on **every push to every pull request** through `pull_request_target`. On this repository, that queued about 265 runs within a day, the oldest since 15:27 UTC. They wait in the same runner queue as `CI` (53 queued, the oldest since 14:41 UTC), `No Game Data` (59) and `Runtime` (29). I'm sorry about that. This PR: - **Drops the `pull_request_target` trigger.** Every run already checks all open pull requests, so the push-to-`main` and hourly runs cover what the per-PR runs did. A rebased pull request now loses the label within the hour instead of right away. - **Puts every run in one concurrency group (`conflict-label`).** At most one run is in progress and one waiting, and a newer push replaces the waiting one. - **Removes the per-PR `--pr` argument from the workflow.** The workflow also no longer has a trigger that gives a fork's pull request a write token. - **Updates `tests/test_pr_conflict_label.py`.** It now checks that no `pull_request` / `pull_request_target` trigger, per-PR group or `--pr` comes back. The tool's docstring and the `CONTRIBUTING.md` line describe the new schedule. **Runs that are already queued** will still run under the old workflow file. Each one is harmless but holds a runner slot. Someone with write access can clear them; the next push to `main`, or the hourly run, re-labels everything: ```sh for s in queued pending; do gh run list -R ubiquitarianism/leonida --workflow conflict-label.yml --status "$s" --limit 1000 \ --json databaseId --jq '.[].databaseId' | xargs -r -n1 gh run cancel -R ubiquitarianism/leonida done ``` ### Tested - `tests/test_pr_conflict_label.py`: OK. Against the workflow on `main` (the old triggers), the new `test_no_run_per_pull_request` fails, as it should. - `tests/test_ci_registration.py`, `tests/test_docs_links.py`, `tests/test_text_write_line_endings.py`: OK. - The workflow YAML parses: triggers `push`, `schedule` and `workflow_dispatch`; concurrency `{group: conflict-label, cancel-in-progress: false}`. GPUs tested: n/a (CI only) AI-assisted: yes (Claude Code) ### Checklist - [x] Based on current `main` and merges cleanly (a conflicting pull request is labeled `needs rebase`). - [x] One topic; follow-up work goes in a new pull request. - [x] No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here. - [x] A new translator rule is in the contract table of `docs/design.md`, with how it was confirmed. (n/a)
aslan2142 commented 2026-11-24 20:59:26 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by aslan2142 on 2026-11-24T20:59:26Z.


Merged. Reviewed and checked locally:

  • Claim: valid. PR-CONFLICT-LABEL-LOAD was posted before the PR and is unedited.
  • The change: the per-pull-request trigger is gone and every run shares one concurrency group, so at most one run is in progress and one waiting. Each run already checks every open pull request, so the push-to-main and hourly runs cover it. A rebased pull request now loses the label within the hour.
  • The load was real: when I checked, 346 of the 861 waiting runs in this repository were this workflow's (279 queued, 67 pending).
  • Local checks on 364754de5: tests/test_pr_conflict_label.py, the tool stdout, startup and line-ending guards, all 12 test_docs_* files, check_no_game_data.py and the tool's --help pass. actionlint was not run here.

I'm cancelling the labeler runs still queued from the old trigger. The push to main from this merge and the hourly run re-label everything.

AI-assisted (Claude Code, Claude Fable 5.2).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7144327106 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/1250#issuecomment-7144327106). Originally posted by [aslan2142](https://github.com/aslan2142) on 2026-11-24T20:59:26Z. --- Merged. Reviewed and checked locally: - **Claim:** valid. `PR-CONFLICT-LABEL-LOAD` was posted before the PR and is unedited. - **The change:** the per-pull-request trigger is gone and every run shares one concurrency group, so at most one run is in progress and one waiting. Each run already checks every open pull request, so the push-to-`main` and hourly runs cover it. A rebased pull request now loses the label within the hour. - **The load was real:** when I checked, 346 of the 861 waiting runs in this repository were this workflow's (279 queued, 67 pending). - **Local checks on `364754de5`:** `tests/test_pr_conflict_label.py`, the tool stdout, startup and line-ending guards, all 12 `test_docs_*` files, `check_no_game_data.py` and the tool's `--help` pass. `actionlint` was not run here. I'm cancelling the labeler runs still queued from the old trigger. The push to `main` from this merge and the hourly run re-label everything. AI-assisted (Claude Code, Claude Fable 5.2).
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
ProjectLeonida/mandy!1250
No description provided.