ci(arm): send the token the step reads, not the literal *** the arm step has been sending #2089

Merged
jaylouisw merged 3 commits from ci/1119-0427 into main 2026-11-19 05:05:26 +00:00
Owner

What was broken

The arm gate has presented the three characters *** as its API token since c6053d2e (merged 2026-11-18T20:53Z). Forgejo answered 401 access token does not exist on every arm, and the job reported success every time, because the status read above it still works anonymously on a public repository.

Evidence (/actions/tasks + job logs):

  • 78 of 78 arm attempts that reached the merge POST between 2026-11-18T20:57Z and 2026-11-19T04:26Z were refused 401 - run 6667 (task 17344) through run 7081 (task 18572, #2087).
  • Last authenticated arm POST: 2026-11-18T20:49:57Z, run 6660, HTTP 409 head out of date (auth OK, pre-c6053d2e code).
  • Consequence: #2085, #2086, #2087 and #2088 reached every-check-green and sat open; every merge in that window came from the scheduled pass, never from the gate.

Change

  • ${TOKEN} restored at the three sites that carried the literal: the arm POST and the refusal comment in ci.yml, and the post-push status read in auto-rebase.yml.
  • A 401/403 from the arm POST now fails the job (::error + exit 1) instead of a green check that armed nothing. 405/409/5xx keep the comment-and-stay-green behaviour.
  • A 409 body now decides between "already scheduled to auto merge" and "head out of date" - the second was being logged as already armed - nothing to do.

Coverage

Unchanged: same status-set reader (every status on the head success, all three CI / Test (Node *) legs present), same head_commit_id pin, same three test legs, smoke and Docker, same 360 suites / 12380 assertions per leg. Only two workflow files changed.

Measured

run task arm job POST result
before 7081 18572 4 s, success 401 access token does not exist
after 7110 18654 3 s, success 409 already scheduled to auto merge - the credential is accepted

All 8 statuses on c18e53b4 green; the pull request merged as 7b05a168 at 05:05:26Z.

Still open (next increment): a fresh 201 armed did not cause a merge on this instance - #2089 sat armed and green for 20 minutes and merged instantly on a direct POST /merge without merge_when_checks_succeed. The queue that is supposed to fire on the arm appears not to run here.

## What was broken The arm gate has presented the three characters `***` as its API token since c6053d2e (merged 2026-11-18T20:53Z). Forgejo answered `401 access token does not exist` on every arm, and the job reported **success** every time, because the status read above it still works anonymously on a public repository. Evidence (`/actions/tasks` + job logs): - 78 of 78 arm attempts that reached the merge POST between 2026-11-18T20:57Z and 2026-11-19T04:26Z were refused 401 - run 6667 (task 17344) through run 7081 (task 18572, `#2087`). - Last authenticated arm POST: 2026-11-18T20:49:57Z, run 6660, HTTP 409 `head out of date` (auth OK, pre-c6053d2e code). - Consequence: #2085, #2086, #2087 and #2088 reached every-check-green and sat open; every merge in that window came from the scheduled pass, never from the gate. ## Change - `${TOKEN}` restored at the three sites that carried the literal: the arm POST and the refusal comment in `ci.yml`, and the post-push status read in `auto-rebase.yml`. - A 401/403 from the arm POST now fails the job (`::error` + exit 1) instead of a green check that armed nothing. 405/409/5xx keep the comment-and-stay-green behaviour. - A 409 body now decides between "already scheduled to auto merge" and "head out of date" - the second was being logged as `already armed - nothing to do`. ## Coverage Unchanged: same status-set reader (every status on the head `success`, all three `CI / Test (Node *)` legs present), same `head_commit_id` pin, same three test legs, smoke and Docker, same 360 suites / 12380 assertions per leg. Only two workflow files changed. ## Measured | | run | task | arm job | POST result | |---|---|---|---|---| | before | 7081 | 18572 | 4 s, `success` | 401 `access token does not exist` | | after | 7110 | 18654 | 3 s, `success` | 409 `already scheduled to auto merge` - the credential is accepted | All 8 statuses on `c18e53b4` green; the pull request merged as 7b05a168 at 05:05:26Z. Still open (next increment): a fresh `201 armed` did not cause a merge on this instance - #2089 sat armed and green for 20 minutes and merged instantly on a direct `POST /merge` without `merge_when_checks_succeed`. The queue that is supposed to fire on the arm appears not to run here.
ci(arm): send the token the step reads, not the literal *** it has been sending
All checks were successful
CI / Classify the change (pull_request) Successful in 10s
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 18s
CI / Server smoke test (pull_request) Successful in 9s
CI / Test (Node 20) (pull_request) Successful in 1m0s
CI / Test (Node 22) (pull_request) Successful in 1m1s
CI / Docker build (pull_request) Successful in 20s
CI / Test (Node 18) (pull_request) Successful in 1m5s
CI / Arm auto-merge (pull_request) Successful in 6s
1f0a4f1db8
The arm step has presented the three characters `***` as its API token since
c6053d2e (2026-11-18T20:37Z, merged 20:53Z) - the shape a masking tool leaves
behind when a token is written through it. The server answered 401 "access
token does not exist" every time, and the job reported success every time,
because the status read above it still works anonymously on a public repo.

Measured over /actions/tasks and the job logs: 78 of 78 arm attempts that
reached the POST between 2026-11-18T20:57Z and 2026-11-19T04:26Z (runs 6667,
6669, 6672 ... 7076, 7079, 7081, task 18572) were refused 401. Nothing merged
through this gate in that window; #2085, #2086, #2087 and #2088 were green and
open, and every merge since came from the scheduled pass.

Restores ${TOKEN} in the three places that had the literal - the arm POST and
the refusal comment in ci.yml, and the post-push status read in auto-rebase.yml -
and makes a 401/403 from the arm POST fail the job instead of reporting a green
check that armed nothing. Any other refusal keeps its comment-and-stay-green
behaviour. The gate itself is untouched: same status set, same three-leg floor,
same head_commit_id pin.
forgejo-actions force-pushed ci/1119-0427 from 1f0a4f1db8
All checks were successful
CI / Classify the change (pull_request) Successful in 10s
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 18s
CI / Server smoke test (pull_request) Successful in 9s
CI / Test (Node 20) (pull_request) Successful in 1m0s
CI / Test (Node 22) (pull_request) Successful in 1m1s
CI / Docker build (pull_request) Successful in 20s
CI / Test (Node 18) (pull_request) Successful in 1m5s
CI / Arm auto-merge (pull_request) Successful in 6s
to 755ff5bda1 2026-11-19 04:37:48 +00:00
Compare
forgejo-actions scheduled this pull request to auto merge when all checks succeed 2026-11-19 04:39:43 +00:00
ci: re-run after the rebase pass minted a head with no event
All checks were successful
CI / Classify the change (pull_request) Successful in 9s
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 24s
CI / Server smoke test (pull_request) Successful in 9s
CI / Test (Node 20) (pull_request) Successful in 52s
CI / Test (Node 22) (pull_request) Successful in 54s
CI / Test (Node 18) (pull_request) Successful in 1m0s
CI / Docker build (pull_request) Successful in 17s
CI / Arm auto-merge (pull_request) Successful in 3s
edf61aa568
forgejo-actions force-pushed ci/1119-0427 from edf61aa568
All checks were successful
CI / Classify the change (pull_request) Successful in 9s
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 24s
CI / Server smoke test (pull_request) Successful in 9s
CI / Test (Node 20) (pull_request) Successful in 52s
CI / Test (Node 22) (pull_request) Successful in 54s
CI / Test (Node 18) (pull_request) Successful in 1m0s
CI / Docker build (pull_request) Successful in 17s
CI / Arm auto-merge (pull_request) Successful in 3s
to f8ee1c75e9 2026-11-19 04:46:41 +00:00
Compare
ci(arm): a 409 body decides between armed and head out of date
All checks were successful
CI / Classify the change (pull_request) Successful in 13s
PR rebase / Rebase onto main and arm auto-merge (pull_request) Successful in 7s
CI / Server smoke test (pull_request) Successful in 8s
CI / Docker build (pull_request) Successful in 22s
CI / Test (Node 20) (pull_request) Successful in 58s
CI / Test (Node 22) (pull_request) Successful in 1m0s
CI / Test (Node 18) (pull_request) Successful in 1m4s
CI / Arm auto-merge (pull_request) Successful in 3s
c18e53b420
The 409 branch printed "already armed - nothing to do" for both answers this
endpoint gives. Measured on #2089: the same POST answered
{"message":"pull request is already scheduled to auto merge when checks succeed"}
on one head and {"message":"head out of date"} on another, and both were logged
as armed. The server's own words now choose the branch, so a head that cannot be
armed is named instead of reported as done.
jaylouisw canceled auto merging this pull request when all checks succeed 2026-11-19 05:03:11 +00:00
jaylouisw scheduled this pull request to auto merge when all checks succeed 2026-11-19 05:03:11 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
jaylouisw/packetforge!2089
No description provided.