Skip to content

Branch model: state the invariants, tag rulesets, and the one sanctioned bypass - #2833

Merged
chalin merged 31 commits into
docsy:mainfrom
chalin:chalin-m24-branch-model-invariants-2026-0930
Oct 1, 2026
Merged

chalin merged 31 commits into
docsy:mainfrom
chalin:chalin-m24-branch-model-invariants-2026-0930

Conversation

@chalin

@chalin chalin commented Sep 30, 2026 •

Copy link
Copy Markdown
Collaborator
  • Replaces the page's release steps, which prescribed a direct-push merge commit on main that the rulesets refuse, with steps the rules allow
  • Scope:
    • Branch-model page: per-branch invariants, the two tag rulesets, the two release procedures
    • Merge requirements: the two main rules, rebase disabled by policy, the merge gates
    • Restoring the fast-forward path: the one sanctioned bypass, its ordering constraints, and the merge method it depends on
    • Emergency version bump routed through the patch procedure
  • Out of scope:
    • Release steps that predate the model (7, 11, 13-16, 22), including step 16's deploy/prod merge, step 22's missing restore pointer, and the publish workflow's ancestry check against patch tags (follow-up PR)
    • deploy/prod and doc-rooted protection (undecided)
    • Contributing guide's "enforced on every PR" wording (tracked with the LF transfer)
  • Preview(s):

@chalin
chalin requested a review from a team September 30, 2026 09:53
@netlify

netlify Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for docsydocs ready!

Name Link
🔨 Latest commit bf2874f
🔍 Latest deploy log https://app.netlify.com/projects/docsydocs/deploys/6abe7b5b73ce6b0008a1f329
😎 Deploy Preview https://deploy-preview-2833--docsydocs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

- Replaces the ancestry-recording step (a direct-push merge commit on `main`, which the rulesets now refuse) with the invariants each branch keeps and the rulesets that enforce them
- Tags: reachable from `release` and immutable, instead of "created from" it
- Patch workflow: PRs into `release`, fix on `main` first; the duplicated release-PR step stated once
- Publishing updates `deploy/prod` from `release`, as practiced at 0.14.3, not from `main`
- Owner review round 1
- States the goal the ancestry step served: `release` diverges only from a patch on `release` to the next release from `main`, re-aligned by an admin before that release
- Retires "stable vs patch release" for "release from `main` vs patch on `release`": every Docsy release is stable; what differs is where it's cut
- `release`'s ruleset enforces only non-rewriting; checks run on PRs into it and report, with no push gate, because any required check would also refuse the fast-forward from `main` (observed)
- Tags: the ruleset blocks moving `v*` tags, not deletion
- Review round 1 (r1.1, r1.3, r1.5-r1.7) and owner rounds 3-4
- Moves the post-patch precondition to a symptom-first callout at the release step and drops the Patch workflow's step 4; "restores the fast-forward path" replaces "re-aligns `release`", which read as moving `release`
- Cuts "every release's history ends up on `main`" (the retired ancestry promise) and the goal's repeat in the Branch model list
- Patch step 2 goes back onto `main` by PR; `deploy/prod` follows `release` at release time
- Review round 2 (r2.1-r2.5) and owner round 5
… step 1

- The overview dispatches to a General release workflow and the Patch release workflow; the post-patch precondition is the release procedure's first step, not a callout beside it
- Owner round 6 (@chalin's restructure) with conductor's wording pass
- "Release from `main`" and "Patch on `release`" name the two procedures; the overview dispatches by link with the choosing condition inline; the patch section's intro no longer restates its heading
- Owner round 7
- Publishes the ancestry merge for any maintainer: `git merge -s ours release` on a branch off `main`, merged via Bypass rules and merge with the merge-commit method, since the linear-history rule refuses a plain merge commit and the bypass button defaults to squash
- The branch model's release step links it instead of paraphrasing
@chalin
chalin force-pushed the chalin-m24-branch-model-invariants-2026-0930 branch from b6a6009 to e93c503 Compare September 30, 2026 14:23
- Rebase merges are now disabled repo-wide and the ruleset allows squash alone; the intro states the three branch rules and names the one exception
…s is the exception

- Lists the two branch rules; names the one sanctioned bypass as its own statement
- Restore procedure: after the patch's site updates are back on `main` (else that PR compares empty); approval and green checks first, so the bypass overrides only the merge method; a maintainer, not an admin (the bypass actor is the Maintain role)
- Release step 2 names `--ff-only`: a local merge then push is a fast-forward push of a merge commit, which `release` accepts
- Tags: the ruleset blocks updates and restricts creation of `v*` tags; "official" release tags are reachable from `release` (one 2022 pre-release tag is on neither branch)
- `main`'s rules stated once, in the notes; the branch model points there
- Cuts the within-page repeats (tag reachability, "patches may be code not on main", the duplicated publish step, "one sanctioned" twice) and gives § Why a reason instead of a restatement
@chalin chalin added this to the 0.18.0 milestone Sep 30, 2026
@chalin chalin changed the title Branch model: state the invariants the rulesets enforce Branch model and merge requirements: state the invariants the rulesets enforce Sep 30, 2026
- An integrity ruleset with no bypass blocks updates and deletion of `v*` and `theme/v*`; a creation ruleset restricts new release tags to the releaser
- `release` is fast-forwarded to the release commit at release time and stays there between releases: it is the base for patches, so its tip must not run ahead of the latest release
- `deploy/prod` publishing worded by release kind: a fast-forward from `main` also succeeds after a patch, and would publish unreleased docs
- § Why: only `main`'s PR-scoped gates would refuse the fast-forward; push-run checks leave statuses the required-checks rule accepts
- Restore procedure: fetch first and merge `upstream/release` (and `upstream/deploy/prod` when it was updated from `release`); the bypass overrides only the merge method given step 1
- The emergency security bump routes through the patch procedure; the restore trigger is about commits, not content; tags bullets split; smaller wording per round 4
@chalin chalin changed the title Branch model and merge requirements: state the invariants the rulesets enforce Branch model: state the invariants, tag rulesets, and the one sanctioned bypass Sep 30, 2026
- The restore trigger and procedure cover `deploy/prod` too: a site-only cherry-pick diverges it on its own, and the February restore recorded both branches
- Merge list names the extra approval for unattributed Copilot PRs
- The bypass's role is stated as its purpose (preserving the merge commit), not as a narrowing of what it can override
- `release`'s ingress and § Why link the procedures and gates instead of restating them; the emergency bump drops the tag detail Tags owns
- An EasyCLA miss on a `release` PR resurfaces at the restore PR on `main`, where the check is required: said at the checks bullet and in the restore step
- Copilot approvals: the rule raises the total, not the team minimum
- Restore trigger and step name each publishing branch; release step 2 checks out `release` first
- § Why keeps its load-bearing bullets; the Overview closer and "explicitly bypasses" go
- Observed: the method dropdown persists under the ticked bypass and keeps its selection; the step names the checkmark as the thing to verify, and only the linear-history rule as what the bypass lifts
- Two facts the private decision record held that a maintainer needs: rebase merges are off repo-wide (a PR keeps its history), and the ruleset's allowed methods must keep `merge` or the merge box hides it even under a bypass
- The restore trigger names both ways `deploy/prod` diverges: updated after a patch on `release` (the page's own publish step), or a site-only cherry-pick; restoring `release` alone left the `deploy/prod` fast-forward failing at the next release (0.14.3 precedent: docsy#2571 then docsy#2577)
- Release step 2 pushes `release`; the restore branch starts from `upstream/main`
- `deploy/prod` "follows `release` at release time" reconciled with the fast-forward from `main`: the same commit after a release from `main`
- Three prose nits: an aside, a repeated opener, a tense
Drop the site-only cherry-pick case: `deploy/prod` has never carried commits
of its own. A docs-only fix to the released content reaches it through
`release`, fast-forwarded from `main` before the version params move on.
The restore trigger is now `release` alone.
The restore procedure records `release`'s ancestry only (r9.1); `deploy/prod`
did carry one commit of its own in the past (6ff036a, docsy#2571), a PR that the
fast-forward from `release` now replaces. The release step pins the
fast-forward to the release tag and orders the restore before the
release-preparation PR (r9.3); the docs-only fast-forward window is dropped
(r9.2): the published docs change only when `release` moves.
`release` moves when the release tag is pushed, not after downstream testing
(r10.1): the tag is already the point of no return, and the published docs
follow it. The patch procedure names cherry-picks on both legs (r10.8); the
restore commands set no upstream tracking (r10.10); the extra-approval gate
uses GitHub's definition instead of its label (r10.3).
The precondition check reads remote-tracking refs, so it needs a fetch first
(r11.1). The patch PR squashes fix and site updates into one commit, so the
return leg is a port, not a cherry-pick (r11.2; 0.14.3's docsy#2573 did the same).
Drops the doubled `v` in the tag example (r11.3).
…link-cache seeds

A PR from `release` itself would carry the patch's version stamps onto
`main` (r12.1), so the port is a copy onto a branch off `main`; the restore's
ordering prerequisite loses its reason and goes. Four seeds for files that are
now on `main` are dropped to force their re-check (the notes' seed convention).
@chalin
chalin merged commit 71694cf into docsy:main Oct 1, 2026
14 checks passed
@chalin
chalin deleted the chalin-m24-branch-model-invariants-2026-0930 branch October 1, 2026 18:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant