feat(agent): run the ship gate on every push, draft included - #844
Merged
Conversation
A draft push was free: no check, no lint, no tests. That let broken commits reach a branch reviewers and other agents pick up, and made CI the first thing to notice. This is a library monorepo — the gate is `pnpm check` → `pnpm lint` → `pnpm test`, with no browser or API suite a draft could usefully defer — so it now runs on every agent push whatever the PR state. The HEAD-SHA cache already keeps a commit from being validated twice, so pushing then publishing still pays once. Pushes no longer consult `gh` at all: PR state cannot change the outcome. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@effect-app/cli
effect-app
@effect-app/eslint-codegen-model
@effect-app/eslint-shared-config
@effect-app/infra
@effect-app/vue
@effect-app/vue-components
commit: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
A draft push was free — no check, no lint, no tests. Broken commits reached
branches that reviewers and other agents pick up, and CI was the first thing to
notice.
What
The ship gate now runs on every agent push, whatever the PR state. This is a
library monorepo: the gate is
pnpm check→pnpm lint→pnpm test, with nobrowser or API suite a draft could usefully defer, so there is nothing left to
exempt a draft from.
How
pre-pushno longer resolves PR state at all —ghcannot change the outcome,so asking it was only a way to fail.
shouldRunShipGateOnPushis gone with itslast caller;
resolveOpenPrStatestays for the publish path.The existing HEAD-SHA cache is unchanged, so pushing a commit and then
publishing it still pays for the gate once.
Remarks
Sibling PRs in macs-scanner and macs-configurator keep a cheaper "static" scope
for drafts, because those gates do have an expensive e2e half worth deferring.
Verified by this branch's own push: the full gate ran green before the branch
went up.
🤖 Generated with Claude Code
Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.