Skip to content

ci(pr): require a sync, a capped topic, or a native stack onto quattro - #83

Merged
mark-groves merged 7 commits into
quattrofrom
cursor/pr-shape-gate-6c3e
Oct 18, 2026
Merged

mark-groves merged 7 commits into
quattrofrom
cursor/pr-shape-gate-6c3e

Conversation

@mark-groves

@mark-groves mark-groves commented Oct 17, 2026 •

Copy link
Copy Markdown
Owner

Why

Agents have landed upstream imports on quattro under topic titles (#78, 1150 files) and merged a hand-built stack layer straight onto quattro (#75). Stacked pull requests are the preferred way to split work, and GitHub's native stacks are now generally available, so this check makes small native stacks the easy path and rejects the shapes that caused those incidents.

What the check enforces

  • Sync (cursor/upstream-changes-pr-*, cursor/fork-upstream-updates-*, i18n-sync): targets quattro; only one upstream sync open at a time. i18n-sync and an upstream sync don't block each other. Syncs are not capped.
  • Topic or stack layer: at most 40 files against the branch it targets, so every layer of a stack is capped, not just the bottom.
  • Stacks of any depth: a pull request not targeting quattro must sit in a stack whose trunk is quattro. The trunk comes from GitHub's native stack metadata (PullRequest.stack.baseRefName over GraphQL), falling back to walking open pull requests for hand-built stacks.
  • No upstream commits outside a sync: a topic or layer may not carry commits from the fork parent's quattro that its base lacks. Stacking on the open sync is fine.

The post-merge check is gone: it could only report after the fact, and native stack merges land layers on quattro, which it would have flagged.

AGENTS.md gains a Pull Requests section telling agents to build stacks with gh stack and merge them bottom-up through GitHub.

The unrelated-looking polkit commit removes two allowlist entries upstream no longer has; nothing installs those files and the migration deletes them.

Verification

🤖 Generated with Claude Code

cursoragent and others added 2 commits October 17, 2026 03:54
Nothing writes the USB and Thunderbolt polkit actions anymore. The comment that said default/polkit copies them was false.

Co-authored-by: ai <ai@id.grovr.au>
A topic on quattro may change at most 40 files. Over that, the check tells the author to split into a stacked pull request set whose root targets quattro. The same job runs the layout and polkit shell tests. A merged pull request must keep the base tip it named as the merge commit's first parent.

Co-authored-by: ai <ai@id.grovr.au>
@coderabbitai

coderabbitai Bot commented Oct 17, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 211202ce-b809-4d7f-b928-85b141af3d7f
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit a9748a2. Configure here.

Comment thread .github/pr-shape-check.sh Resolved
Comment thread .github/pr-shape-check.sh Resolved
cursoragent and others added 4 commits October 17, 2026 06:18
i18n-sync is the auto-PR that collects translations onto quattro. A full collect changes more than 40 files, so the topic cap blocked it. The cap stays a hard failure for every other topic, with no override label.

Co-authored-by: ai <ai@id.grovr.au>
The closed event's base SHA lags the branch GitHub merged onto, and a rebase of more than one commit does not parent that snapshot. Fetch the named branch and accept the merge when that branch contains it, or when its tip is still what the first-parent chain reaches.

Co-authored-by: ai <ai@id.grovr.au>
Read the stack trunk from GitHub's native stack metadata, falling back to
walking open pull requests, so a stack of any depth whose bottom targets
quattro passes. Hold every topic and stack layer to the 40-file cap against
its own base, and reject upstream commits outside a sync branch. Drop the
post-merge check: it could only report after the fact and native stack
merges would trip it. The tests now use local fixtures instead of a
hard-linked clone, which failed when /tmp is on another filesystem.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@mark-groves mark-groves changed the title ci(pr): reject a pull that is not a sync, a topic, or one stack ci(pr): require a sync, a capped topic, or a native stack onto quattro Oct 18, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@mark-groves
mark-groves merged commit 643a55a into quattro Oct 18, 2026
4 checks passed
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.

2 participants