ci(nightly): accept a pre-resolved stack via source_ref - #91
Merged
Conversation
When the rebase onto upstream conflicts the nightly fails in prepare, and the ruleset stops a human from force-pushing the resolved stack to main from the CLI. Add a source_ref dispatch input: the run checks out that ref instead of main, rebases it onto upstream, verifies it, publishes the release, and promotes it to main through the existing backup and lease mechanics. Combined with dry_run it verifies a resolution without publishing or promoting anything. That splits what fork_ref used to cover on its own. fork_ref stays the stack being published (the checkout, and the commits release notes enumerate); the new main_ref output is main's tip when the run started, read once in prepare and used for the backup snapshot, the moved-main skip, the lease, and the nothing-to-promote short-circuit. That short-circuit now compares the candidate against main rather than against the stack source, since on a source_ref run the rebase is expected to be a no-op while promotion still has work to do. On scheduled runs the two outputs are the same commit and behavior is unchanged. Model: Claude Opus 5, harness: T3 Code
incognitojam
enabled auto-merge
August 11, 2026 16:40
incognitojam
added this pull request to the merge queue
Aug 11, 2026
This was referenced Aug 11, 2026
incognitojam
added a commit
that referenced
this pull request
Aug 11, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 11, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 12, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 12, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 12, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 13, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 13, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 13, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 13, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 14, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 14, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
incognitojam
added a commit
that referenced
this pull request
Aug 15, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 18, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 18, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
yngatech-nightly Bot
pushed a commit
that referenced
this pull request
Aug 18, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
incognitojam
added a commit
that referenced
this pull request
Aug 19, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
incognitojam
added a commit
that referenced
this pull request
Aug 19, 2026
## Problem The `source_ref` dispatch that fixed the conflicted patch stack promoted a resolution cut before today's workflow PRs merged, rolling `main`'s workflow state back: #87 (promote every verified run), #90 (require workflow jobs directly), #91 (`source_ref` input), and #92 (yngatech-nightly app token) were dropped. The moved-main lease only guards movement during a run, not whether the provided stack already contained everything on `main`. ## Fix Cherry-pick the four squash commits back onto the promoted stack, in original merge order. The restored `.github/workflows/fork-nightly.yml`, `.github/workflows/fork-ci.yml`, and `docs/operations/fork-nightly.md` are byte-identical to their pre-rollback state (verified with `git diff` against the old `main` tip). A follow-up should make `source_ref` runs fail when the provided stack is missing patches present on `main` (patch-id comparison in prepare). --- Written by an agent (Claude Code, claude-fable-5).
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.
When the nightly rebase onto
pingdotgg/t3codeconflicts, the run fails in prepare and a maintainer resolves the stack locally — but the ruleset blocks force-pushingmainfrom the CLI, so there was no way to get the resolved stack back ontomain.This adds an optional
source_refdispatch input. The run checks out that ref (a branch or SHA pushed to origin holding the resolved stack) instead ofmain, rebases it onto upstream (a no-op when nothing moved since, a loud conflict failure when it did), runs the full verification, publishes the release, and promotes it tomainthrough the existing backup and lease mechanics. An invalidsource_reffails in a pre-checkout validation step with a readable message. Pairingsource_refwithdry_runverifies a resolution without publishing or promoting anything.The
fork_refsplitToday the run always checks out
main, so one commit serves every role. Withsource_refthere are three: M =origin/main's tip, R = the provided stack, C = the candidate after the rebase.fork_refkeeps its meaning as the stack source (R) and a newmain_refoutput carries M, resolved once in prepare so every later check compares against the same snapshot.FORK_SOURCE_REFin both changelog stepsmainagainst the run-start snapshot.--force-with-lease=refs/heads/main:…)main's expected value.source_refrun C == R is the normal case and promotion still has work to do; the real question is whethermainis already the candidate.The prepare job's no-change alignment step gets the same treatment (all four of its uses are M). On scheduled runs
fork_refandmain_refare the same commit, so behaviour is unchanged.Verified with actionlint (only the pre-existing blacksmith runner-label warning) and by extracting every
run:body from both this workflow and the pre-change one and replaying them against stubbedgit/gh: scheduled runs produce identical command sequences, and thesource_refpaths cover promote, C == M no-op, moved main,dry_run, and invalid ref.Model: Claude Opus 5, harness: T3 Code