Skip to content

docs(minicloud): correct the merge runbook against what the merges did - #15750

Merged
dimakr merged 1 commit into
masterfrom
docs/minicloud-runbook-corrections
Aug 12, 2026
Merged

docs(minicloud): correct the merge runbook against what the merges did#15750
dimakr merged 1 commit into
masterfrom
docs/minicloud-runbook-corrections

Conversation

@fruch

@fruch fruch commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

What

Corrects docs/plans/minicloud-stack-merge-runbook.md, which landed with #15617 and turned out to be wrong in three places once it was actually executed. Docs only, one file.

1. A GitHub stack object is separate from the base refs, and it is what blocks the merge

The runbook assumed base refs were the whole story, so it said GitHub would auto-retarget on merge and nothing else was needed. In reality these three PRs were bound into stack #15619 (size 3), and while it existed:

gh stack unstack 15619 dissolved it and left every base ref untouched, so the dependents kept their clean 8- and 2-commit diffs. Now documented with how to read the stack number, that gh stack link is the inverse, and that gh pr merge --rebase --admin gets an admin past a missing approval (enforce_admins is false on master).

2. jenkins/precommit does not necessarily clear when the base becomes master

The runbook claimed it "should flip from fail to pass" after the restack, treating the failure as purely a stacked-PR artifact. It did not flip — the artifact was masking a real failure, and both look identical from outside. #15618's console had them one after the other:

fatal: ambiguous argument 'origin/master..HEAD': unknown revision or path not in the working tree.
ruff-format..............................................................Failed

The first line is the stacking artifact (baseHash derived from an unreachable merge ref). The second was genuine: two files in #15618's own commits failed ruff format --check while passing at master. Now says to check the changed files directly, with the commands, and to fix via --fixup + --autosquash rather than leaving fixup commits.

3. git checkout -B <pr-branch> can silently rebase the wrong branch

git checkout -B feature/minicloud-pipelines pr/15618 fails with "already used by worktree at ..." when that branch is checked out elsewhere — and because the following git rebase is a separate command, it then runs on whatever branch you were already on. Mine produced 10 commits instead of 8 before I caught it. The runbook now uses a scratch branch name and pushes with an explicit HEAD:<branch> refspec.

Also refreshed: Step 1 and 2 marked done with the SHAs the merge actually produced, the stale OLD_BASE=139b5499db replaced (15617's head moved when the runbook commit was added to it — the point of reading it rather than remembering it), --force-with-lease pins switched to git ls-remote, and a note that #15668 must be restacked after any force-push to #15618, not only after its merge.

Tests

Docs only — no code paths touched. pre-commit clean on the changed file.

🤖 Generated with Claude Code

@scylladb-promoter

scylladb-promoter commented Aug 10, 2026

Copy link
Copy Markdown
Collaborator

✅ Test Summary: PASSED

✅ Precommit: PASSED

Total Passed Failed Skipped
15 15 0 0

✅ Tests: PASSED

Total Passed Failed Errors Skipped
4656 4625 0 0 31

Full build log

@fruch fruch added P3 Medium Priority docs PR/issue regarding SCT docs labels Aug 10, 2026
@dimakr dimakr added the backport/none Backport is not required label Aug 12, 2026
Three things the runbook got wrong or did not know, all found while executing it:

A GitHub stack object is separate from the base refs and was the actual
merge blocker. 15617's base was already master, yet the button stayed
unavailable and retargeting 15618 was refused outright — stack #15619 had
to be dissolved with 'gh stack unstack'. The runbook had assumed base refs
were the whole story.

jenkins/precommit does not necessarily clear when the base becomes master.
On 15618 the stacked-PR baseHash artifact was masking a real ruff-format
failure in two of its own files; both look the same from outside, so the
changed files have to be checked directly.

'git checkout -B <pr-branch>' fails when that branch is checked out in
another worktree, and the following rebase then runs on the wrong branch.
Use a scratch name and push with an explicit HEAD:<branch> refspec.
@dimakr
dimakr force-pushed the docs/minicloud-runbook-corrections branch from 7c7d46f to 4da46f1 Compare August 12, 2026 20:33
@dimakr
dimakr merged commit 2cd4ee6 into master Aug 12, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai-assisted backport/none Backport is not required docs PR/issue regarding SCT docs P3 Medium Priority promoted-to-master

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants