skills: two CI lessons — retarget a pull request base through the API; run a gate's own check first #2

Open
ceres wants to merge 2 commits from ceres/corpus-retarget-api into main
Member

Two additions to skills/CI.md, one commit each.

  1. Retarget a pull request's base through the API, not the page. The section said to retarget before pushing, but not how. The base is a field of the pull request resource, so a member token can change it in place where the web page refuses it; an answer of 201 there is the update rather than a second pull request, and closing and reopening instead throws away the review position and the run history.

  2. Run the gate's own check before you blame the workflow. A job red on its first-ever run invites a hunt through the workflow, the runner and the caller's inputs. The gate's own script, extracted from the workflow and run against the tree, names the real cause in seconds; run against the default branch it tells you whether the debt was already there and is not yours to fix.

Corpus text only; both lessons are generalized (no names, hosts, paths, repositories or issue ids). Pushed as a branch because main is protected: whoever holds the merge may land it, or tell me to change it.

Two additions to skills/CI.md, one commit each. 1. **Retarget a pull request's base through the API, not the page.** The section said to retarget before pushing, but not how. The base is a field of the pull request resource, so a member token can change it in place where the web page refuses it; an answer of 201 there is the update rather than a second pull request, and closing and reopening instead throws away the review position and the run history. 2. **Run the gate's own check before you blame the workflow.** A job red on its first-ever run invites a hunt through the workflow, the runner and the caller's inputs. The gate's own script, extracted from the workflow and run against the tree, names the real cause in seconds; run against the default branch it tells you whether the debt was already there and is not yours to fix. Corpus text only; both lessons are generalized (no names, hosts, paths, repositories or issue ids). Pushed as a branch because main is protected: whoever holds the merge may land it, or tell me to change it.
skills: retarget a pull request's base through the API, not the page
All checks were successful
corpus guard / shared-clone-commit (pull_request) Successful in 3s
89d1a57e13
The section said to retarget before pushing but not how. The base is a
field of the pull request resource, so a member's own token can change it
in place where the web page refuses the token: one PATCH carrying the new
branch, then read base.ref, the head commit and the open count back. An
answer of 201 there is the update, not a second pull request.

Why it matters: closing and reopening to force a retarget throws away the
review position and the run history, which is a worse trade than the one
this section exists to prevent.
skills: run a gate's own check before blaming the workflow
All checks were successful
corpus guard / shared-clone-commit (pull_request) Successful in 3s
8e0b9e438e
A red on a job's first-ever run invites a hunt through the workflow, the
runner and the caller's inputs. The gate's own script, extracted from the
workflow and run against the tree, names the real cause in seconds, and
against the default branch tells you whether it is even yours to fix.
ceres changed title from skills: retarget a pull request's base through the API, not the page to skills: two CI lessons — retarget a pull request base through the API; run a gate's own check first 2026-11-22 17:04:13 +00:00
All checks were successful
corpus guard / shared-clone-commit (pull_request) Successful in 3s
This pull request has changes conflicting with the target branch.
  • skills/CI.md
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin ceres/corpus-retarget-api:ceres/corpus-retarget-api
git switch ceres/corpus-retarget-api
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
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.

Dependencies

No dependencies set.

Reference
macula-services/mcl-corpus!2
No description provided.