Skip to content

feat(dev-fleet): pin a worktree to the stable release channel - #10066

Closed
cixuuz wants to merge 1 commit into
mainfrom
feat/dev-fleet-release-channel-worktrees
Closed

cixuuz wants to merge 1 commit into
mainfrom
feat/dev-fleet-release-channel-worktrees

Conversation

@cixuuz

@cixuuz cixuuz commented Sep 11, 2026 •

Copy link
Copy Markdown
Contributor

Problem / Motivation

You cannot click through a shipped release from Dev Fleet. The fleet lists feature
worktrees, and every one of them is unreleased code. To see what stable actually
shipped you leave the dashboard, find the tag by hand, and make a checkout yourself.

Dev Fleet manages git checkouts, and a git checkout has no release channel.
platform/update_capability.py says so in as many words: "Only the wheel command
carries a channel. A git checkout follows its remote."

Why it matters

A bug report says "broken in stable". Answering it means running stable. Today that
is manual work outside the tool that exists to manage checkouts, so it mostly does
not happen — and a fix gets tested against main instead of against the build the
reporter is on.

What changed (motivation → approach → change)

Dev Fleet grows one row, release-channel-stable: a real worktree detached at the newest
published stable release. Pods and Make Live already drive any fleet row, so a shipped
build now boots the same way a feature branch does.

Moving part What it does
release_channel_pin.py resolves the channel tip: newest bare vX.Y.Z tag by semver, read from a private tag mirror (refs/dev-fleet/release-tags/*), never from refs/tags/
worktree_ops.py Create one argument-less mutation: refuse if the reserved name is already held or ambiguous, fetch, resolve, ask the remote for exactly the resolved tag and refuse any other oid, worktree add --no-checkout --detach at a staging path, probe that staging worktree's own config for a content-filter driver and refuse if one is declared, populate with reset --hard, adopt with worktree move
fleet_state.py publishes the row's state in the /fleet payload: adopted, placeholder, unpublished, taken, error
DevFleetPage.tsx the row and its copy: version badge carrying the row's currency, BEHIND marked n/a like PR, placeholder with Create, and honest wording when less is known
Prune never offers empty for a detached worktree, so the pin cannot be auto-reaped

One channel, on purpose. nightly tags nothing, so a nightly row would just be main.
insider tags do resolve, but ordering -insider.N against -rc.N needs a rule this
repo does not state. CHANNEL is a single "stable" constant with no channel parameter
anywhere; a second channel is a shape change made when that rule exists.

flowchart LR
  subgraph Before
    A1[want to run stable]:::ctx --> B1[leave the dashboard]:::removed
    B1 --> C1[find the tag, clone by hand]:::removed
  end
  subgraph After
    A2[want to run stable]:::ctx --> B2[Create on the stable row]:::added
    B2 --> C2[detached worktree at v0.5.0]:::added --> D2[Pod / Make live]:::ctx
  end
  classDef added fill:#DCFCE7,stroke:#16A34A,color:#14532D,stroke-width:2px
  classDef removed fill:#FEE2E2,stroke:#DC2626,color:#7F1D1D,stroke-dasharray:4 3
  classDef ctx fill:#E0F2FE,stroke:#0284C7,color:#0C4A6E
  linkStyle 0,1 stroke:#DC2626,stroke-dasharray:4 3
  linkStyle 2,3,4 stroke:#16A34A,stroke-width:2px
Loading

🟩 added · 🟥 removed · 🟦 unchanged

Creating the row is now the whole job; the pod controls were already there.

The mirror is the safety story. The operator writes refs/tags/ too — a local v99.0.0
sorts newest and, read from there, became the channel tip.
Resolution reads only the pruned mirror, so "published" is a property of where a ref
lives rather than a claim about how it got there. Create adds two more refusals before it
touches disk: a resolved oid the remote does not advertise, and a filter.<name>.* driver
declared in git config, which the checkout would execute. That probe runs from inside the
staging worktree after a --no-checkout add and before the populate, because a
[includeIf "gitdir:…"] include is evaluated against the worktree being operated on —
probing the primary checkout could miss a driver scoped to the staging path. Before the
populate, git is asked where the working tree is: a core.worktree in that config would
send reset --hard into an arbitrary directory, so a redirected answer refuses.

The pin never moves in place: a newer release is Remove then Create. Nothing here reads or
writes $KIROCREW_HOME/channel.

The row says less when it knows less, and says it where it is read. A release row's
currency lives on its version badge (its tooltip names the tip, says the tree is at it,
or says the tip could not be resolved); BEHIND on that row reads n/a, like its PR cell,
so the column keeps one meaning — commits behind main — for every row that has one. With
nothing fetched yet the status line says that Create is the fetch; with a version
resolved it says which one Create checks out. When an adopted tree sits on no release tag
its badge reads not on a release — the tree's condition, never the bare lane word, which
on a row already named release-channel-stable reads as a version — and a placeholder with
nothing resolved shows no version pill at all. A branch checkout holding the reserved name
is told the name is reserved and how to free it. While a placeholder shows, the count beside the filter reads
N worktrees · 1 to create, so it agrees with Worktrees (N) instead of contradicting it.

The full reasoning behind each mechanism is under Design notes below.

Every area this diff touches

Path Why it changed
src/kiro_crew/apps/builtins/dev_fleet/release_channel_pin.py resolution: the tag mirror, semver ordering, the worktree-state read
src/kiro_crew/apps/builtins/dev_fleet/worktree_ops.py the create mutation, its staging path and cleanup, the refresher's fetch
src/kiro_crew/apps/builtins/dev_fleet/http_api.py the create route and its static SEL audit target
src/kiro_crew/apps/builtins/dev_fleet/server.py route registration
src/kiro_crew/apps/builtins/dev_fleet/fleet_state.py publishes the channel row in the fleet payload
src/kiro_crew/security_posture.py allowlists release_channel_pin as a non-core-egress redactor — it scrubs git stderr before that text becomes a row's error
website/src/pages/DevFleetPage.tsx the row, the placeholder, the version badge, the behind cell — and the copy each shows when it knows less than usual (nothing fetched, tip unresolved, no release tag)
website/src/components/appstore/appManifest.ts one App Store highlight for the feature
website/src/i18n/locales/*.json, website/src/i18n/en.context.json the row's strings in 13 catalogues plus the pseudolocale, and translator context for the short labels
website/capture/devfleet-release-channel.{html,tsx}, website/scripts/capture-devfleet-release-channel.mjs, website/.jscpd.json the screenshot harness: nine row states, the three Create outcomes and the open row menu behind a stubbed /fleet, and the by-file duplication exemption every capture entry carries
website/scripts/check-bundle-size.mjs the i18n all chunk ceiling re-measured to the file's 5% convention: main alone sat 0.28% under it, this branch's catalogue copy (35 KB across 13 languages, same 14 modules, no library) crossed it by 232 B — see Design notes
docs/system-specs/modules/dev-fleet.md the owning spec section
docs/feature-map/README.md the feature-map row
test/test_dev_fleet_release_channel_pin.py, test/test_dev_fleet_release_channel_ops.py, test/test_dev_fleet_component_boundaries.py, test/test_dev_fleet_app.py, website/src/test/DevFleetPageReleaseChannels.test.tsx the coverage described under Tests

Design notes

Why each mechanism above has the shape it has. Every paragraph here answers a review round;
none introduces a mechanism the table under What changed does not name.

Dev Fleet grows one more row: release-channel-stable, a real worktree detached at
the newest stable release. Pods and Make Live already drive an ordinary fleet row, so a
shipped build now boots the same way a feature branch does.

One channel, and the two left out are left out for different reasons. nightly
cannot be resolved from git at all: nightly.yml builds from main HEAD on a schedule
and tags nothing, so the newest ref a nightly row could name is origin/main — which is
main now, not the commit the last nightly published, and is where the primary checkout
already sits after Sync. A row promising "what nightly shipped" while showing neither
duplicates main and misleads about which build it is.

insider is out by product decision, and its tags do resolve — ranking them is what has
no answer. Ordering -insider.N against -rc.N needs a precedence nothing in this repo
states, so a prerelease tip would rest on a rule this feature invented. One channel whose
order is a fact beats two where one is a guess.

The surface is singular, and that is a decision rather than an omission.
release_channel_pin.CHANNEL is a single "stable" constant, not a tuple. There is no
channel parameter, no channel key in either request body, no map from channel to resolved
tip, and no list in the payload — each of those would be a shape with exactly one possible
value, and one no caller could vary. The mutation endpoint therefore takes no argument at
all, which is also what retires the validation an earlier shape needed: a value that
cannot be sent cannot be rejected, sanitized, or smuggled into a git ref or a directory
name. It also lets the route declare its SEL audit target statically instead of reading
one out of the request body — and the worktree routes' fallback chain is spelled inline at
its one use site rather than behind a named constant, which was a rider with a single
consumer and identical behaviour. Admitting a second channel is a change to this module's
shape, made when the precedence rule for prerelease tags exists to justify it — not a
parameter carried in advance of it.

Create is not dashboard/handlers/worktree.py's creator, and that is a different
problem rather than a duplicate one.
That creator solves two races: a branch-ref race
(_claim_branch writes refs/heads/<branch> with an empty old-value, letting git's ref
lock pick the winner) and a directory race (atomic os.mkdir as proof-of-creation).
Create here checks out a DETACHED worktree at a resolved oid, so there is no branch to
claim and that half has no analog; its destination is a module constant rather than
caller-supplied, so there is no repo allow-list to enforce. What remains is the directory
race alone, which staging decides by construction instead of by inferring ownership from
an mkdir that raced. The two now AGREE on content filters, and that agreement replaces a
divergence this description previously argued for: both refuse a repo declaring
filter.<name>.process/.smudge/.clean. The earlier argument for allowing it here — that
refusal would make a legitimately published release un-materializable — does not survive
scrutiny: a filter driver can only be defined in git config, config is never committed and
never travels with a clone or a fetch, so checking out a release tag cannot introduce one and
no tracked .gitattributes in this repo even names a filter. The refusal can therefore only
fire when the operator's own checkout already carries a local driver, which is precisely the
hostile case. release_channel_pin.repo_supplied_filter probes --local plus --worktree
(the latter only when extensions.worktreeConfig reads true via --bool, and only when the
config.worktree file exists), with --includes mandatory so a repo-controlled
include.path cannot hide a driver. Global config is deliberately unread: git lfs install
writes filter.lfs.* there, so probing it would refuse Create on every git-lfs host. That
probe runs at the strict tier — it reads local config and needs no network, so it needs no
credentials — while the two network calls stay at standard, which is the credential-bearing
tier a private remote requires. The git env neutralizers are not bypassed either way: every
git child here goes through runtime._run_cmd, which applies _GIT_ENV_NEUTRALIZERS to all
of them, and content filters are the one class that dict cannot disarm — which is why this
path refuses them outright rather than trying to contain them.

The probe runs inside the mutation lock, from inside the staging worktree, between a
--no-checkout add and the populate, with no network call between.
It is a point-in-time
read, so its distance from the populate it protects is the whole of what it guarantees — and
its context matters as much as its timing: a [includeIf "gitdir:**/…staging…"] include is
evaluated against the worktree git is operating on, so a driver scoped to the staging path is
invisible to a probe of the primary checkout and visible to exactly the probe that runs there.
A real-git test plants such an include and asserts the primary probe misses it and the staging
probe reports it. A second real-git test sets core.worktree under extensions.worktreeConfig
and asserts the working-tree check names the redirect while a clean staging tree answers with
itself; the fake-git sequence test pins add → probe → working-tree check → populate. Measured against git 2.54, a filter.<name>.smudge does
execute during worktree add --detach, and no by-construction dissolution exists:
GIT_CONFIG_NOSYSTEM and GIT_CONFIG_GLOBAL=/dev/null reach only system and global config
while the driver lives in local .git/config, which git always reads; -c filter.<n>.smudge=
suppresses only a name known in advance, and the name is attacker-chosen; --no-checkout
leaves an empty index so the populate runs the filter — which is why the probe sits between the
two; and git archive | tar -x runs the smudge filter too. Ordering is therefore the available remedy rather than a preference —
the window is the gap between two local spawns instead of two network round-trips. The honest
cost is that a filter-declaring repo now pays a fetch it did not need, which is the same fetch
the status refresher already runs every cycle and so writes nothing new. strict constrains
the git child and its descendants, not an independent process writing .git/config; what it
gives is that a filter reaching execution runs credential-free inside the sandbox.

The obvious design does not work, and that is why this one looks the way it does.
Pinning the primary checkout to a release cannot work: Sync refuses to run unless
HEAD is main, and it fast-forwards with git merge --ff-only. A stable tag is
normally behind main, so that merge is refused. The only ways through are detaching
main's HEAD — which the sync guard rejects, and which silently repoints every
origin/main comparison on the row — or resetting main backwards, which destroys
work. So the channel gets its own tree instead. Nothing existing changes shape.

release_channel_pin.py resolves the channel to a tag, ordered by semver descending.
Creation date is not that order: a backport cut after a newer line (v0.4.2 tagged
after v0.5.0) is the newest tag by date and an older release by version, and a
re-pushed tag carries today's date for last year's release. Either would pin the row to a
release stable users are not on. Parts compare numerically, so v0.10.0 beats v0.9.0,
and the key is apps.version.parse_version — the repo's one version parser, not a
second parse written here. A tag counts as a release only if it is a bare vX.Y.Z;
that shape check is the channel decision, because such a string has no suffix left for
a classifier to read. The resolver never re-checks the tag it just selected, and the
tag LISTING asks git for no order at all: _release_candidates re-sorts by semver, so a
--sort=-creatordate there had no consumer — and worse than inert, it read like the
order the tip is chosen by, which is the exact mistake this paragraph exists to prevent.

One mutation sits in worktree_ops.py beside the other worktree writers, under the
same .git admin lock. It fetches tags before resolving: the background refresher keeps
the rows current on its own schedule, so a mutation that resolved first would act on
whatever the tag mirror held at that moment and call the result the tip.

The pin never moves in place, and that is a decision. There is no Advance: a newer
release is Remove then Create, which the fleet already offers. An in-place checkout of
a tree that already exists has to reason about everything already in it — a branch someone
put it on, a dirty file, a commit stranded on a detached HEAD, build artifacts belonging to
the previous release — and each of those is a guard whose failure mode is silent. Every one
of them was written, reviewed and then deleted with the control they served.

What Remove + Create costs is real and worth naming: the provisioned tree
(node_modules, built dist, venv — has_dist is a filesystem check inside the worktree,
so a re-created channel comes back unprovisioned), the pod (its identity is the worktree
basename, so removal stops the service and drops its port), and the live-target pointer,
which names a path removal deletes. On a control used about once per stable release, that
is the cheaper side of the trade — and it is two clicks the fleet already had.

Prune merged never offers the channel worktree, and that guard is against a plausible
deletion rather than a theoretical one. A pin is detached (no branch, so no PR), clean,
and holds no commits the base branch lacks — a release tag is an ancestor of main — which
is precisely the empty verdict, and past 48h empty is a candidate the prune preview
preselects. So _prunable withholds empty from any tree with no branch, and it
does that rather than match the release-channel-* basename because the name is one
level above the cause. Matching it got both halves wrong: a tree the operator detached by
hand at a release tag — the workflow this automates — carries no channel name and stayed
preselected, while a branch checkout that merely borrowed the reserved name vanished
from Prune merged entirely. Keying on branch is None covers every deliberately detached
tree and lets a branch fall through to the ordinary merged logic. The check lives in
_prunable rather than the caller because the removal path re-asks for a fresh verdict —
one condition covers both the preview and the execution.

The channel resolves from a private tag mirror, not from refs/tags/. Every fetch for
this channel carries +refs/tags/v*:refs/dev-fleet/release-tags/v*, and resolution reads
only that namespace. refs/tags/ cannot be the source of truth because the operator writes
to it too — a locally cut release candidate, a bisect marker, a v99.0.0 tagged to test an
upgrade path. Each matches the stable shape, sorts newest, and under a plain git tag --list became the channel tip, so the row badged an unpublished commit as a shipped release
and Create checked it out. Nothing distinguishes a local tag from a fetched one after the
fact, so the separation has to happen where the ref is written: a mirror the operator has no
reason to write to makes "published" a property of WHERE the ref is rather than a claim
about how it got there. The row's own version probe reads the same mirror, because git tag --points-at HEAD would let a local tag rename the row the same way.

--tags is kept beside the refspec, not replaced by it. The reported ref is a real
refs/tags/vX.Y.Z the operator can check out, and refs/dev-fleet/release-tags/v1.2.3 is
not a thing anyone types; because the channel reads only the mirror, keeping refs/tags/
fresh cannot put a local tag back in the running. An empty mirror is a state rather than an
error — a checkout that has not fetched does not know what is published, so it reads as "no
release found" and the next refresher cycle fills it, while None from the listing stays
reserved for git itself failing.

The mirror is pruned, and the fetch is SPLIT so that pruning is structural rather than
argued.
The refresh issues two fetches. The first names the forced mirror refspec and the
base branch and no tags at all, and carries --prune: a mirror ref the remote does not
advertise is deleted, and refs/tags/ is not among that command's destinations, so an
operator's local tag is not reachable by its pruning even in principle. That is a stronger
statement than the old one, which rested on --prune not being --prune-tags. The second
fetch is the --tags courtesy that populates ordinary tags for the operator's own use; it is
best-effort and its exit status is deliberately not checked.

Splitting them fixes a real refusal as well as strengthening the guarantee. Mixing a forced
refspec with an unforced --tags in one command means a diverged local tag makes the whole
fetch exit non-zero — ! [rejected] v1.0.0 -> v1.0.0 (would clobber existing tag) — even
though the mirror refspec itself succeeded. Because the refresh treats any non-zero as an
error, an operator who ever cut a local tag named like a release could not Create at all.

Without pruning, "the operator has no reason to write here" describes habit and not
enforcement: a ref namespace is writable by anything with repo access, so one git update-ref refs/dev-fleet/release-tags/v999.0.0 <any-commit> outranks every real release by semver and
survives an additive fetch. Two things pay for that, and Create's integrity is not one of them.
The FLEET ROWS pay first: the display path resolves out of the same mirror with no provenance
backstop, so the forged ref is badged as stable. Create's AVAILABILITY pays second: every
resolve picks the forgery and every provenance check refuses it, so Create stays refused until
someone hand-runs git update-ref -d. Create's INTEGRITY is owned by the ls-remote
provenance check below, which refuses any oid the remote does not advertise whether or not the
fetch pruned.

Pruning bounds PERSISTENCE, not timing: --prune deletes only refs the remote does not
advertise at fetch time, so a ref planted between the fetch and the resolve is unpruned and
would be checked out. Create therefore asks the configured upstream what it publishes
for exactly the resolved tag (ls-remote --tags <remote> refs/tags/<tag> 'refs/tags/<tag>^{}')
and refuses unless the resolved oid is the one advertised for it, which closes the ref-planting window at every timing rather than
narrowing it. The scope of that guarantee is stated exactly in the docstring and the spec: the
remote is the one named in the repository's own git config and git reads its URL from that
config, so this defends against a writer who can plant a ref, not against one who can
rewrite remote.<name>.url. A writer with that reach already redirects every fetch this app
performs — including the pre-existing sync that rebases a worktree onto <remote>/main — so a
URL trust anchor would have to be operator-owned state shared by all ten of the app's remote
call sites, which is app-wide hardening rather than this feature's to add (see the deferred
issues below).
The query names the tag's ref AND its ^{} peel pattern explicitly, because an annotated
tag carries its commit only on the peel line; nothing else the remote advertises is asked
for, and nothing else is retained — two hex-validated oids at most, never a map of the
remote's tag population, so a remote with thousands of tags costs the same as one with one.
The mirror listing is bounded the same way, at git: for-each-ref --count of
_MAX_RELEASE_REFS plus one, names capped at _MAX_REF_NAME_LEN, both one named constant.
The extra row, or an overlength name, is MirrorOverflow, raised by the one helper both
listings share (_bounded_mirror_rows) on the raw rows before any name is filtered, and
surfaced as the row's error — from the tip listing a truncated tail would otherwise sort and
could name a release that is not the tip; from the --points-at HEAD probe it would read as
"no release" on a tree that may well be on one.
An unadvertised tag is exit 0 with no output rather than an error, so absence is read from
the (empty) answer. A @requires_git test builds a throwaway repo, cuts an annotated tag,
and asserts the real-git shape rather than the shape this file's fake asserts — with a guard
that the tag object and commit oids differ, or the test would prove nothing about the peel
line.

This hardening is per-path, deliberately. Grepping ls-remote across src/kiro_crew
confirms no other checkout or merge path verifies a local ref against the remote: this path
is the one that resolves a TIP by ranking refs out of a writable namespace, which is what
lets a planted ref decide what gets checked out. The siblings — worktree_ops._sync's
_sync_base_ref() merge and the dashboard creator's checkout — consume a ref the operator
names, so the same check would guard a different threat and needs its own reasoning; both
are deferred rather than silently assumed covered.

--prune-tags is the flag that would reach refs/tags/ and destroy the operator's tags; it
stays refused and a test asserts its absence.

Retraction therefore lands here rather than being deferred: the channel stops resolving a
yanked release on the next fetch, while refs/tags/ stays additive so the operator can
still check such a tag out locally. That closes
#10477.

release-channel-* is a reserved name, so adoption requires the shape: a checkout
is a channel pin only when it is detached. Someone's own branch under that name keeps
ordinary controls and is never adopted as a channel pin, rather than having its HEAD moved
out from under their branch. Its name cell carries a muted sentence, not a pill: On a
branch, so the stable release can't use this name — rename or remove it to free it
, with
the tooltip naming the controls that free it (Prune merged once the branch's PR has merged,
or git worktree move / remove in a shell). It was a pill for three rounds — "Not a
release worktree — on a branch", then "Name reserved — on a branch" — and each wording failed
a different blind read: one was mistaken for the off-tag pill two rows away, the next was
not understood at all ("I wouldn't click anything on this row until I understood it"). A
pill holds a verdict; this state needs a what and a what-to-do, and the row's status-line
slot is where the placeholder already says that kind of sentence ("No worktree yet — Create
checks out 0.5.0"), so it moved there. No warn colour: the row is a healthy branch checkout,
and the sentence explains the row's relation to the lane rather than flagging the row.

A third state the backend can emit needed a rendering path, because neither of the other
two covers it: the reserved directory exists and is a registered, selectable worktree, but
its git state could not be read — worktree is null, name_taken_by_branch is false, and
only error is set. It is therefore neither an adopted pin nor a branch checkout, so
neither existing badge fires; and because the row IS selectable, the placeholder path is
suppressed too, which left the backend's error string with no rendering path at all in the
default view. One derivation (channelErrorFor) now folds this case together with an adopted
row whose resolve() failed, and both reach the SAME row-scoped ErrorNotice with the agent
hand-off — no error string is carried by a badge tooltip, which is neither keyboard-reachable
nor a hand-off. A test asserts the notice surfaces that error, and nulling either branch of the
derivation fails it.

The placeholder is suppressed whenever a real directory already carries that reserved
basename — tested on the NAME, not on a classification. worktree and
name_taken_by_branch are both classifications, and a third state exists: an unreadable
HEAD resolves to detached: null, which is neither, so the placeholder rendered beside
the very directory it was describing and one directory became two rows. The name is the
thing that can only belong to one row, so guarding on it holds for classifications added
later too.

The channel rides in a release_channel key of its own, not as an extra worktrees
row. A channel with no tree has no path, and every consumer of a worktrees entry —
disk measurement, pod matching, prune candidacy — assumes one. The row carries no behind
count: the behind-main number on a release worktree is large by construction and names no
action, and three wordings of a tip-denominated count in the BEHIND cell (↓3 tip,
↓3 newer, tooltips) each drew a different misread from a blind reader. So the cell says
the column does not apply (n/a, as the PR cell does), the field and the rev-list probe
that fed it are gone, and the version badge carries the currency in its text — 0.5.0 · latest 0.5.3 when behind, the bare version at the tip — with the tooltip saying which, or that the
tip is unknown. "latest", not git's "tip": a blind reader said the word "means nothing to me
otherwise" and guessed; "latest" is the update banner's own word and needs no guess.
It names no control: closing the gap is Remove then Create, two controls on two surfaces,
and naming one would misdirect.

A row's version is the release that row is on, and the two row kinds differ: a
placeholder shows what Create would check out (the channel tip), an adopted row shows what
its tree actually holds, read from git tag --points-at HEAD and filtered to the channel's
own tags. tip_version carries the tip alongside it. Publishing the resolved version on
an adopted row made the badge rename itself to each new release as it shipped while the
checkout stayed put, so the row claimed a build it did not contain. version is null
when the tree is detached at no release tag at all — adoption is by shape, not by being
at a release — and the row says that rather than borrowing the tip.

A channel that will not resolve gets a row-scoped ErrorNotice with the agent
hand-off, on the adopted row and the placeholder alike — one derivation feeds both, so the
notice is the SOLE surface the backend's error string reaches. The placeholder's cell text
states the failure compactly with a short plain label carrying no error string, and the notice
under the row is what makes it keyboard-reachable and hands it to the agent. It is
deliberately NOT the
page-level surface: that error arrives on the fleet poll rather than from a button, so
notifying there fired on every mount for any checkout with no v* tags (a shallow
clone, a fork before its first release), for a feature that operator never used.

The placeholder row reads as muted by dimming its own CELLS, never the grid container.
An opacity < 1 on the container composites the whole subtree as one group and a
descendant cannot exceed its ancestor's opacity, so a container opacity dims the Create
button — the one control the row exists to offer — along with the muted text. The muting
therefore sits on the pod-column dash and the worktree cell, which are siblings of the
actions cell, and a test walks the button's ancestors and fails if any of them carries a
reduced opacity.

The fleet table is a DESKTOP-ONLY surface and now says so at its layout root, which is
what the narrow-viewport-required rule's own exemption asks for. The header grid owns a
fixed 640px seven-column contract that every row matches, and the columns are read across
rows as one aligned diagnostic table — so a lone responsive row would misalign from its own
header, and the placeholder shares the header's grid exactly rather than diverging from it.

Create runs at the strict git tier and is drained across cancellation. worktree add
materializes repo-controlled content and runs whatever content filter that tree
configures, which the env neutralizers do not cover, so the gateway's trusted credential
helpers would otherwise be reachable from a filter defined by the very release tag being
checked out. Draining matters because a cancellation releasing the git mutation lock
mid-write leaves a half-registered worktree behind.

Create builds at <channel path>.staging.<pid>.<rand> and adopts it with git worktree move. The destructive cleanup on failure can therefore only ever name a directory this
call made, and move — which refuses an existing destination — is what decides a race
between two gateways. Inferring ownership from an earlier path-exists check could not:
_GIT_MUTATION_LOCK is an asyncio lock, so a second gateway on the same repo can create
that path between the check and the add, and the cleanup would then force-remove its
worktree.

A return is not the only way out, so that cleanup also runs on the unwind. Each git
child is shielded by _run_uninterruptible, which re-raises CancelledError once it
returns, so a backend shutdown can unwind the frame between a successful worktree add
and the move that adopts it — and the rc != 0 cleanups are only reached by a
returning failure. A BaseException handler discards the staging tree and re-raises,
because swallowing the cancellation would make a shutdown look like a completed Create.
It narrows the window rather than closing it, and what survives is bounded on purpose: a
<path>.staging.<pid>.<rand> directory the operator's own git worktree remove reclaims and that
cannot block a retry, since the guard tests the lane path and every call stages under a
fresh name. The cleanup that runs when Create fails is ONE scoped command, worktree remove --force <staging>, which drops the staging record whether or not its directory still exists;
it used to be followed by a repository-wide worktree prune, which covered nothing the
staging path needed and would have unregistered any unrelated worktree whose directory was
momentarily absent — an unmounted volume is the ordinary case — with no undo. Gone; a
real-git test keeps both records' directories missing and shows only the staging one leaves.

A channel that will not resolve now gets an ErrorNotice with the agent hand-off,
scoped to its row. Every other error class on the page already had one; a resolver
failure reached the user only through the version badge's tooltip and the placeholder's
cell text, neither keyboard-reachable and neither offering the hand-off. It is row-scoped
and sits below the grid rather than at page level, because the page-level surface would
fire on every mount for a checkout with no release tags at all — a shallow clone, or a
fork before its first release — which is a normal state and not an incident. The compact
framed sentence stays in the row so the grid still reads at a glance.

The Create success toast names the control it sends the operator to. It used to end
"provision from the row menu", but Provision renders as a standalone row button and is in
no menu — so every success sent the operator somewhere the control is not. The clause is
gone from the string in all 13 catalogues; the code appends the button's own label instead,
prefixed "next:", so it reads as an instruction rather than a bare noun after a dash — and
cannot drift from what the button says.

A Create FAILURE is not a toast. The backend's refusal — a content filter, a redirected
working tree, an ambiguous name — or a transport error is kept in component state and
rendered under the placeholder row through the same ErrorNotice with the agent hand-off,
until the operator retries or dismisses it; a toast would have carried the diagnosis away
while the worktree stayed uncreated. Four tests pin the notice, its persistence across a
fleet refetch, and its clearing on retry and dismiss.

Presence-based provisioning is a real gap this PR does NOT touch, and deleting Advance is
what took it out of scope. prov.has_dist is dist_dir().is_dir(), so any operation that
rewrites tracked content in place leaves a tree reporting provisioned with artifacts from
before the rewrite — _rebase_locked and Sync's git merge --ff-only both do. Advance
would have been a third, which is why it carried an artifact-invalidation subsystem
(_BUILD_INPUTS, _discard_dir, needs_provision) that existed for no other reason. With
Advance gone, all of it is gone and this PR adds no new in-place writer. The cause is filed
as #10459: build provenance per
artifact, so has_dist can mean "present AND built from this HEAD", which closes both
existing siblings.

The background refresher fetches the same two things every cycle, which is load-bearing
rather than tidy. Without it the mirror is refreshed only inside a mutation, so at_tip
reads true against a stale mirror and the version badge and behind count both describe a
tip that has already moved. With no in-place advance, the row's report IS the whole product
of resolution — the operator decides whether to remove and re-create from what it says — so
a stale one is the only failure mode left. Both fetches use the refspec constant rather than
spelling it out, because a drifted second spelling fails silently: the channel would resolve
against a mirror nothing updates, which is indistinguishable from a repo that has published
nothing new.

None of this touches $KIROCREW_HOME/channel. That file says which channel your install
follows for updates; a pin here says which ref a worktree sits on. CHANNEL is the
literal "stable" re-declared in this module rather than indexed out of
update_layout.RELEASE_CHANNELS — a single constant needs no tuple, and importing one to
take [0] would imply an ordering that tuple does not promise. A test is what keeps the
two from drifting: it asserts the name is still a channel the update stack knows, and it
is the only place the tuple is imported.

The i18n all chunk ceiling moves, and the file's rule is that the PR moving it says
why.
main alone builds that chunk at 12,498,868 B against a 12,533,760 B ceiling —
0.28% headroom, the same drift the file's own history records five times: a ceiling that
was 5% over a measurement gets eaten by ordinary catalogue copy until the next feature's
strings trip it. This branch adds 35,124 B across 13 catalogues (row states, Create
outcomes, the reserved-name sentence and its tooltip) and crosses by 232 B. Attribution is
measured, not assumed: the chunk holds the same 14 modules on both refs, so no library
reached it, and no lazy import() boundary can move a catalogue string out of all. The
ceiling goes back to the 5% convention over the measurement that includes this branch.

Tests

test_dev_fleet_release_channel_pin.py (44) covers resolution. The load-bearing one
is that the channel skips newer prerelease tags — this repo's real tag history has
v0.6.0-insider.6 newer than v0.5.0, so a resolver that ignored the shape filter
would hand back a prerelease and look successful. Others pin that the channel name is
still one the update stack knows and that the other two are out; that a release tag is
classified by shape alone and never disagrees with the shared release rule; that a
non-release tag is rejected at the shape check; that the resolver never re-decides a tag
it already picked; that a tag is peeled to a commit; that one broken local ref does not
report the channel as unpublished; that an empty channel is reported rather than guessed;
and that the pruning fetch carries --prune while naming no tag refspec at all, because
pruning the mirror is what bounds a forged ref, and keeping refs/tags/ out of that
command's destinations is what keeps the operator's own tags unreachable by it. A further
test pins that a diverged local tag does not fail the refresh, which is the refusal the
split removes. Four cover ordering: a backport tagged after a newer line does
not become the tip, version parts compare numerically (v0.10.0 beats v0.9.0), a
prerelease never becomes the tip even when it is newest, and candidate order is
deterministic under a reordered listing. Seven cover the release a tree is actually on: a
behind row reports its own version and not the tip, a foreign tag sharing the commit
cannot rename the row, an at-tip row takes the version from the already-resolved answer
without spending a second git call, an unreadable HEAD is neither detached nor on a
branch, and — in worktree_state and again through fleet_state — a failed tip lookup
leaves the tree's own release on the row with at_tip unknown rather than relabelling a
tagged checkout "not on a release" (both fail on the previous early return, which is how
that misreport survived: frame 07 showed a state the backend never produced).

Seven cover the publication boundary the mirror draws, and all four affected code paths were
mutation-checked by reverting the fix and watching the named test fail: a local-only
v99.0.0 is never a candidate (asserted by which namespace is queried, since that is the
whole mechanism), the version probe ignores a local tag on the checked-out commit, an
unfetched mirror reads as unpublished while a failed read reads as an error, the fetch
populates the namespace the resolver reads (asserted against the module's own constant,
because a second spelling is what would drift), --tags still refreshes the operator's
namespace, and the payload reports refs/tags/vX.Y.Z while the oid comes from the mirror
ref. One more lives in test_dev_fleet_app.py: the background refresher's fetch carries the
same refspec, which is the copy whose drift would be silent.

test_dev_fleet_release_channel_ops.py (47) covers the mutation, the payload and the
routes. Eleven cover Create: it refuses when the worktree already exists and when the path is
occupied by name, fetches before it resolves, reports a failed fetch instead of resolving
against stale local tags, reports a failed worktree add with git's own message, does not
leave the channel uncreatable after that failure, builds at a staging path and adopts it
with worktree move so the destructive cleanup can only ever name a directory it made,
never force-removes the lane path itself, runs without credential helpers, cleans up with
a single scoped remove --force and no repository-wide prune (a real-git test registers a
staging record and an unrelated worktree, deletes both directories, and shows only the
staging record leaves), and — CANCELLED
between the add and the adoption — still discards its staging tree on the way out while
letting the cancellation propagate. One pins the result's key set exactly, so a field
cannot return as a diagnostic without the reader that justifies it. Eleven cover the
content-filter probe that guards the checkout: Create refuses a repo-declared filter
driver, the refused key name is redacted before it reaches the dashboard (the <name> in
filter.<name>.smudge is repository-authored, and the refusal lands in the row notice and
the agent hand-off), the probe lands with no network call before the checkout, a driver planted after
the fetch still refuses, the probe follows config includes, it always probes the worktree
scope once the extension is on (a file written after an existence check would otherwise be a
scope the probe never read), it accepts every git boolean spelling of the enabling extension,
git's own "config.worktree: No such file or directory" is the one failure read as an empty
scope while a malformed file still refuses, it never reads
the operator's own machine config, an unreadable scope refuses the Create, and it matches
only executable filter keys. Six cover the provenance the remote supplies: Create refuses
a tag the remote does not publish, refuses a published tag whose local oid was rewritten,
resolves an annotated tag through its peel line, refuses when the remote cannot be asked,
asks for exactly the resolved tag and its peel pattern, retains one oid even when the
remote answers with five thousand unrelated tags, refuses a non-release tag before any
network call, and — against real git rather than the fake — confirms an annotated tag
advertises its commit on that peel line. Two cover credential
scope on either side of that boundary: the filter probe runs without credential helpers,
while the remote-facing calls keep theirs. Ten cover the
payload: an unmaterialized channel publishes as a placeholder, a detached worktree is
adopted and counted behind the tip, an adopted row on no release tag reports no version, a
branch checkout sharing the name is NOT adopted, the row does not claim "on a branch" when
the probe could not read HEAD at all, the worktree basename is published, an unresolvable
channel keeps its row and carries the error, and the key is None when resolution raises
or there is no checkout. Three cover the route boundary: the mutation route takes no
request argument, a release-channel route audits the worktree it acts on against a body
carrying a decoy name, and a worktree route given only a channel field audits against
nothing rather than borrowing it. Three assert the prune guard in the state that would
delete a pin — a detached tree is never offered however it was made, a branch checkout
holding the reserved name still is, and _prune_candidates end to end, because a right
verdict that reached the wrong list would still be preselected for removal.

DevFleetPageReleaseChannels.test.tsx (34) covers the rows: the version badge and its
two states, the placeholder row that carries Create, BEHIND and PR both rendered as
inapplicable on a release row, and a branch checkout sharing the
reserved name keeping its ordinary controls. Three pin the badge's honesty and the
badge's scope: a behind row shows the release it holds with the tip only in the
tooltip, a tree on no release tag says so instead of showing the tip, and a channel whose
resolution failed carries that error on the row. One more covers the
adopted-but-unresolvable channel — worktree present, resolution failed — which reaches the
same shared ErrorNotice as the unreadable reserved directory, because an adopted row has no
placeholder to carry the
text. One walks the Create button's ancestor chain and fails if any of them dims it,
which is what keeps the row's muting on cells rather than on the container.

Six pin what the row says when it knows less than usual. An unpublished lane's status
line says that Create is the fetch, and the enabled button carries the same answer as
its tooltip — while a lane with a resolved version gives the button no tooltip, because
the pill beside it already says what Create checks out. A row whose resolver failed
keeps n/a in BEHIND and its badge tooltip says the tip could not be resolved — never
presenting the tree's own tag as the tip. The resolved placeholder's status line names the
version Create checks out.
An off-tag adopted badge reads not on a release — never the bare lane word — and its
tooltip carries no ?; a behind badge shows 0.5.0 · latest 0.5.3 in its text, not only in
its colour; the placeholder renders no version pill at all when nothing resolved,
because its status line already says so. While a placeholder shows, the count beside the
filter reads N worktrees · 1 to create; Worktrees (N) and the stat card count worktrees only.
Filtering for the lane row counts it: the row is pinned under main rather than sorted with
the feature rows, and a numerator read off the sorted list alone showed 0 / N for a filter
whose one match was on screen — the test fails on that numerator and passes on the fix.
And a filter that hides the unreadable-HEAD lane row conjures no Create placeholder for the
directory that exists: the name check reads the unfiltered fleet, not the filtered rows, and
the test fails when it reads the filtered set.

One test pins the property that decides whether the private mirror may be replaced by the
ls-remote answer Create verifies against: it resolves the channel with every ls-remote
and every fetch failing, asserts the published version still lands on the row, and
asserts the resolver issued no network argv at all. Sourcing row resolution from the
advertisement fails it, which is the point — the fleet is deliberately offline-tolerant
(PR lookups degrade to null on any git or gh failure so rows still render), and the
release row participates in that render only because resolution reads .git.

Manual verification

No real-instance run, and the reason is a sandbox fence rather than a shortcut not
taken.
This worktree has its own venv whose editable install points at its own
src, so an instance from it is unambiguously this branch's code — that part is
settled. What stops it is that a from-source gateway dies at boot under the agent
sandbox:

PermissionError: [Errno 1] Operation not permitted: '/Users/<user>/.kiro/crew-auth-staging'

That path is derived independently of KIROCREW_HOME, so pointing the data dir
elsewhere does not avoid it, and pods are fenced separately (launchctl bootstrap
returns EIO in the same sandbox). Run bash minimal_install.sh && ./dev-backend.sh
from a native terminal and it comes up; the channel then resolves against this
repo's real tags.

What was verified instead, on this exact head, from a worktree venv carrying the CI-pinned
toolchain. The related-test selection the profile gates use: 1052 backend test files —
37,681 pass, 67 fail, and 66 of those 67 fail identically on origin/main in the same
sandbox (file-explorer path policy, design-tweak 403s, doctor host probes, a
symlinked scratch path); the one remaining, test_cli_doctor.py::…names_the_vault, passes
alone on both trees and is order-dependent under xdist. 610 frontend test files (16,283
tests) pass, including the diff-scoped fr/bn style rules, and the 19-check i18n
chain plus the i18n render pass diff-scoped against the base. One claim in this PR was
settled by experiment rather than reading: five fresh repos, one per fetch form,
established that --prune-tags does nothing here and that every form which does prune a
retracted tag also deletes local-only tags. That result is what the fetch split acts on:
rather than arguing a flag combination is safe for refs/tags/, the pruning fetch names
no tag refspec, so the operator's tags are not among its destinations at all. Retraction
still lands, because the resolver ranks refs out of the pruned mirror namespace rather
than out of refs/tags/.

Of the profile's 54 gates, 53 pass. The one failure is test:electron, which needs
website/electron/node_modules that this worktree does not have; this diff touches no
file under website/electron/, and CI's own Electron Shell Tests lane passed on the
previous head. The full backend suite is not run at every head — it is roughly an hour
at 16 workers — and CI's shards are the authority on it.

Screenshots / video

Thirteen frames, captured from a committed harness
(website/scripts/capture-devfleet-release-channel.mjs driving
website/capture/devfleet-release-channel.tsx) that mounts the real DevFleetPage
with fetch stubbed at the network seam. Every row state under review is decided by
the /fleet payload, so no gateway, no real release tag and no real worktree are
needed for the page to render the state under review — an earlier revision of this
section claimed the opposite and it was wrong. Each scene waits on its headline text
before shooting, the absence claims are asserted as absences, whether Create is live
is asserted as a control state rather than left to the eye, and the run compares
frame byte sizes because two identical frames are what a broken fixture looks like. The
Create trio drives the Create button itself against a stubbed POST /release-channel/create
(never settling, succeeding, failing), so the busy label, the success toast and the failed-
Create notice are evidence rather than described; the last frame opens the release row's menu.

Adopted, behind the tip. The version badge reads 0.5.0 · latest 0.5.3 — the newer
release in its text, not only in its warn colour, and "latest" rather than git's "tip"; BEHIND reads n/a like PR, directly above a feature row
reading ↓12 from main — one column, one meaning.

Adopted stable lane: release-channel-stable carries a badge reading 0.5.0 · latest 0.5.3, and its BEHIND and PR cells both read n/a beside a feature row counted from main

Adopted, at the tip. The steady state a lane spends most of its life in: the badge
takes its ok variant, so "nothing to do here" reads at a glance.

At the channel tip: ok-variant 0.5.3 badge, BEHIND n/a, beside a feature row counted from main

Placeholder. The only surface the feature is discoverable from. The name, version
pill and status are dimmed on their own cells while Create worktree sits outside
any opacity-reduced ancestor at full contrast, which is what makes the row read as an
offer rather than as something disabled.

Placeholder row: the lane name, the 0.5.0 pill and the status line "No worktree yet — Create checks out 0.5.0" render muted while Create worktree stays at full contrast; the filter count reads 2 worktrees · 1 to create

Nothing fetched yet. A shallow clone or a fork before its first release. Benign
and documented, so it reads as information: the status line says that Create is the
fetch ("No stable release fetched yet — Create fetches the newest one"), the enabled
button repeats that as its tooltip, and there is no version pill: the sentence already
says nothing resolved, and a pill saying it again beside an orange badge on another row
read as two states sharing one label. No ErrorNotice: this is not an incident.

Nothing fetched yet: the status line names Create as the fetch, no version pill, Create worktree stays live

Resolver failure, placeholder variant. A genuine git failure. Create is disabled,
the cell keeps a short label ("The stable release channel could not be resolved") it can
ellipsise without cutting a clause, and the full message reaches the row-scoped
ErrorNotice with the agent hand-off. Compare the
Create button here against the frame above: same row, opposite control state.

Resolver failure on the placeholder: Create is disabled, the cell keeps a short label and the full git message sits in the row ErrorNotice

Resolver failure, adopted variant. The row keeps the release its own tree holds
and its ordinary controls; only the tip is unknown, and the row says exactly that: the
badge tooltip says the tip could not be resolved instead of naming one. The failure
routes to the same ErrorNotice rather than to a Badge title, which is not
keyboard-reachable.

Resolver failure on an adopted row: it keeps the 0.5.0 release its tree holds while the failure routes to the same row-scoped ErrorNotice

Adopted, on no release tag. Adoption is by shape, so a lane tree an operator
detached at an arbitrary commit is still the lane's row. The version slot reads
not on a release — the tree's condition, so it cannot be confused with the resolver-error
row above — never the bare lane word, and the tip is named in its tooltip.

Adopted row detached at no release tag: the badge reads not on a release, with the channel tip in its tooltip

Reserved name held by a branch checkout. Not adopted, so no version badge and no
lane controls: the name cell carries the muted sentence On a branch, so the stable release can't use this name — rename or remove it to free it (no pill, no warn colour — the row is a
healthy branch checkout), and Behind is an ordinary behind-main count.

A branch checkout occupying the reserved basename is not adopted: no version badge, an ordinary behind-main count of 5, and a muted sentence after the name: On a branch, so the stable release can't use this name — rename or remove it to free it

Create, in flight. The button reads Creating… and is disabled for the duration, so a
second click cannot start a second fetch-and-checkout of the same reserved name.

Placeholder row mid-Create: the action button reads Creating… and is disabled; the row is otherwise unchanged

Create succeeded. The toast names what was created and the next control by its own
label — Created stable worktree at 0.5.3 — next: Provision — while the fleet refetch
replaces the placeholder with the fresh row: at the tip (bare 0.5.3, ok variant), not built,
and the Provision button the toast points at sitting on the row.

Success toast reading Created stable worktree at 0.5.3 — next: Provision above the fresh release-channel-stable row: not built, ok-variant 0.5.3 badge, Provision button; Needs Provision now 1

Create failed. Not a toast: the refusal is a persistent ErrorNotice under the
placeholder row, quoting git's own message with the reason it did not happen in front of it,
with Ask the agent and a dismiss control; Create is live again for a retry.

Failed Create: a red ErrorNotice under the placeholder row reads Could not create the release-channel worktree: git worktree add: fatal: release-channel-stable is a missing but already registered worktree, with Ask the agent and a dismiss button; Create worktree is enabled again

Reserved directory, unreadable HEAD. The third state the backend can emit: the directory
exists but its git state could not be read, so it is neither an adopted pin nor a branch
checkout. One row, not two — no Create placeholder appears beside the very directory it would
describe — no version badge, and the error reaches the row's ErrorNotice with the agent
hand-off.

One release-channel-stable row with no version badge and no Create button; below it a red ErrorNotice reading git rev-parse HEAD: fatal: not a git repository, with Ask the agent

Row menu, open. The release row keeps the ordinary controls except Rebase, which has no
meaning for a detached checkout of a tag: Spin up pod, Make live and QA video are there,
Rebase onto main is not.

The release-channel-stable row's actions menu open, listing Spin up pod, Make live and QA + video, with no Rebase onto main entry

website/.jscpd.json gains a by-file exemption for the capture entry plus a sentence
naming the sibling it descends from, following the convention that file already
records for eleven prior harnesses. The shared part is the /fleet stub pair and the
createRoot/provider render block every capture entry must spell identically; the
same file states that sharing a runner was considered and rejected, because each
harness is pinned to its own fixture and assertions.

Related Issues

The feature itself came from a direct request, not a filed issue. It does now fix one:
pruning the tag mirror is what stops a retracted release resolving as the channel tip.

Follow-up filed from review, not closed by this PR:
#10459 — per-artifact build
provenance, so has_dist can mean "present AND built from this HEAD"; it also covers the
same gap in _rebase_locked and Sync's --ff-only.
#10691 — the config-filter probe
siblings diverge across three components, and md_notebook's boolean read misses four git
spellings; the consolidation question is recorded there because the match sets and security
tiers are divergent by design. The files.py instance of that bug class is already tracked as
#10332.
#10692 — a detached worktree never
ages into the empty verdict, so hand-detached trees accumulate and Prune never offers them.
#12342 — a hermetic release-channel
checkout that consults no repository-supplied config, retiring the probe-then-populate
sequence and the sub-millisecond config-rewrite residual the security lane fenced; a design
pass across the six probe sites in #10691, not a patch to this one.
#12353 — the status refresher runs the
courtesy --tags fetch every cycle on every install; keep it on the Create path only.
#12354 — Create's disk cost stated on
the placeholder row before the click.
#12355 — the unresolved-channel notice
says the same thing on a placeholder and on an adopted row; the adopted one should name the
tip check as what failed.

Closes #10477

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

@cixuuz
cixuuz requested review from a team and iamwhatever September 11, 2026 04:39
@cixuuz

cixuuz commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

Intent: Let Dev Fleet run a shipped release. Each published channel (stable,
insider, nightly) gets one worktree, detached at what that channel last published,
so a build a bug report names can be podded next to the branch being written.

Not a goal: Changing which channel the user's own install updates from. Nothing
here reads or writes $KIROCREW_HOME/channel. Also not a goal: downloading released
artifacts, pinning the primary checkout to a lane, or advancing a lane automatically.

@github-actions github-actions Bot added readiness: checking Automated validation is still running readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Sep 11, 2026
@github-actions

github-actions Bot commented Sep 11, 2026 •

Copy link
Copy Markdown
Contributor

GPT 5.6 Review — 🔴 changes requested (blocking)

GPT 5.6 found at least one blocking issue that must be resolved before merging 4daa88559009b9f3791ac479d4eb6869810b4ac2. 1 of 1 blocking finding(s) are security-class and were withheld from adjudication, so the blocking verdict stands.

This comment is updated in place on each push.

BLOCKING -- src/kiro_crew/apps/builtins/dev_fleet/worktree_ops.py:3077 -- Mutable git config can redirect or execute during checkout
if not offending and not redirected:
Config changed after probes -> Create route -> reset --hard executes a filter or overwrites a redirected tree.
Anchor: residual/security
Fix: Populate without consulting repository-controlled configuration.
[BLOCK-MERGE] 4daa885
[GPT-REVIEWED] 4daa885

Adjudication (Opus 4.8) — is blocking on each finding proportionate?

F1 concerns a TOCTOU residual the code itself documents at worktree_ops.py:3060-3064: git config remains writable by another process in the sub-millisecond gap between the filter/redirect probes (repo_supplied_filter at :3065, _worktree_redirected_away_from at :3076) and the reset --hard populate at :3078. Harm class is unbounded (repo-config-driven filter execution or working-tree redirect writing outside the worktree = code execution / out-of-tree write).

Conditions confirmed this run: (a) probes and populate share one _GIT_MUTATION_LOCK window with no network call between them (:3019, :3058); (b) config is read before reset, so an attacker must plant a malicious filter.*/core.worktree AFTER a clean probe but BEFORE reset — a tight but not self-contradicting race requiring config write access. Recovery: a detected filter/redirect refuses and calls _discard_failed_lane_creation (:3114-3139); the residual is precisely the un-detected in-window write, which has no recovery. Defense-in-depth is the strict tier's credential masking (:3062-3064), but that does not stop non-credential code execution or an out-of-tree overwrite.

The timing window is genuinely narrow, but it is not impossible or contradictory, and a local attacker with config write can retry across staging attempts. On an unbounded code-execution class I cannot complete a rarity record strong enough to say a human would plausibly accept the residual — when torn, UPHOLD-FENCED.

[ADJUDICATION] 4daa885 total=0 uphold=0 downgrade=0
[GPT-ADJUDICATED] 4daa885
[ADJUDICATION-FENCED] 4daa885 fenced=1 flagged=0
UPHOLD-FENCED F1 src/kiro_crew/apps/builtins/dev_fleet/worktree_ops.py:3077 -- Sub-millisecond probe→reset config race is tight but real and retryable, yielding unbounded filter-execution/out-of-tree-write harm the strict tier does not fully close.
[GPT-ADJUDICATED-FENCED] 4daa885

False positive or not applicable? A repository writer can comment:
/ai-review override gpt 4daa88559009b9f3791ac479d4eb6869810b4ac2: <one-sentence reason>

@cixuuz
cixuuz force-pushed the feat/dev-fleet-release-channel-worktrees branch from 6ff7f84 to 6b92300 Compare September 11, 2026 04:41
@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Sep 11, 2026
@github-actions

github-actions Bot commented Sep 11, 2026 •

Copy link
Copy Markdown
Contributor

UX Review (Fable 5) — 🟡 CONCERNS

UX-level review of 4daa88559009b9f3791ac479d4eb6869810b4ac2 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

UX-Verdict: CONCERNS

Edge-state rows contradict themselves: "ready" beside a fatal git error, and the reserved-name row's recovery steps hide in a tooltip.

Watch

  • Unreadable-worktree state (shot-12): the row keeps its "ready" pod pill while the new ErrorNotice below says fatal: not a git repository — reader: "I can't tell which to believe … no idea what state the row is really in." Rare state, but it stalls the operator every time it occurs. Smallest fix: when channelUnreadableFor fires, add a short muted note in the name cell (same slot as reserved_name_on_a_branch) so the row and the notice agree.
  • Reserved-name row (shot-08): "rename or remove it to free it" — reader: "renaming or removing things I don't understand feels risky," and the actual how (Prune merged, git worktree move/remove) lives only in release_channel_name_taken_by_branch, a tooltip. Task-gating info demoted below its task; rare state, but the visible sentence alone is unactionable. Fix: change the visible string to "…rename or remove this worktree to free the name" and surface "Prune merged removes it once its PR has merged" in visible text, not hover.

Suggestions

  • no_worktree_yet_create_checks_out vs release_channel_unpublished: the reader saw the same row promise "checks out 0.5.0" in one shot and "fetches the newest one" in another and "can't tell why the promise differs" — align the resolved-state string toward "Create checks out the newest release, 0.5.0".

[UX-REVIEWED] 4daa885

@github-actions

github-actions Bot commented Sep 11, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Fable 5) — ✅ PASS

Design-level review of 4daa88559009b9f3791ac479d4eb6869810b4ac2 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

Design-Verdict: PASS

Verify the _prunable widening: every hand-detached worktree now loses empty prune candidacy forever, an accepted cost living only in a code comment.

Suggestions

[DESIGN-REVIEWED] 4daa885

@github-actions

github-actions Bot commented Sep 11, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Fable 5) — ✅ PASS

Premise-level review of 4daa88559009b9f3791ac479d4eb6869810b4ac2 — why this exists and whether the shipped surface is the smallest honest version. Updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

First-Principles-Verdict: PASS

Verify the bundle-ceiling attribution: the 613 KB raise rests on measured numbers (main alone at 12,206 KB, this branch +35 KB) the diff cannot prove.

What this change ships

Inventory (10 items) — 10 justified

Intent: let an operator run and click through the newest shipped stable release from Dev Fleet instead of hand-building a checkout — an ADDITION.

  1. Dev Fleet gains a release-channel-stable row; Create materializes a detached worktree at the newest published stable tag — justified
  2. The row states its currency on a version badge (at tip / behind / not on a release / tip unknown); PR and Behind read n/a — justified
  3. A branch checkout holding the reserved name keeps ordinary controls and is told how to free the name; an unreadable one gets a row-scoped error — justified
  4. The background refresher now fetches the pruned tag mirror plus the operator's tags every cycle, for every install — justified
  5. Prune withholds the empty verdict from any detached worktree (branch checkouts prune normally), with the cost stated — justified
  6. /fleet gains a release_channel object; the argument-less create route audits against a static SEL target — justified
  7. The filter count reads "N worktrees · 1 to create" while a placeholder shows — justified
  8. One App Store highlight for the feature, across 13 catalogs — justified
  9. A screenshot capture harness for the row states, with the by-file jscpd exemption every harness carries — justified
  10. The i18n all chunk ceiling re-measured 12240→12853 KB per the file's own 5% convention — justified

The change has more items (spec section, feature-map row, translator context, pluralKeys, tests); these ten are the ones a person would notice, and the doc updates are mandated same-commit by AGENTS.md.

[FIRST-PRINCIPLES-REVIEWED] 4daa885

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Sep 11, 2026
@github-actions

github-actions Bot commented Sep 11, 2026 •

Copy link
Copy Markdown
Contributor

Opus 4.8 Review — ✅ no blocking findings

Reviewed 4daa88559009b9f3791ac479d4eb6869810b4ac2 — this comment is updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] 4daa885

Verdict parsed from the review's SHA-scoped output markers for commit 4daa88559009b9f3791ac479d4eb6869810b4ac2.

False positive or not applicable? A repository writer can comment:
/ai-review override fable 4daa88559009b9f3791ac479d4eb6869810b4ac2: <one-sentence reason>

@cixuuz
cixuuz force-pushed the feat/dev-fleet-release-channel-worktrees branch from 6b92300 to 3d96cf1 Compare September 11, 2026 07:42
@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Sep 11, 2026
@cixuuz
cixuuz force-pushed the feat/dev-fleet-release-channel-worktrees branch from 3d96cf1 to 412f682 Compare September 11, 2026 07:44
@cixuuz

cixuuz commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

self-added: yes
mechanism: rev-list unmerged-commit guard in _release_channel_advance

  • Advance abandons clean detached commits (span=9dfffee0bb1f)

Fixed. This held, and the dirty check could never have caught it: committing is
exactly what makes a worktree clean again, so status --porcelain is silent on a
detached HEAD carrying unique commits.
Advance now asks rev-list --count <tip>..HEAD and refuses while anything the tip
does not contain is present, naming the count and telling the operator to put it on
a branch. A probe that cannot run is also a refusal — an unreadable answer is not
permission to proceed, which is the same class of mistake as the original.
This ruling covers every variant of "Advance moves HEAD over work that is on no
branch", wherever the checkout call moves to.

@cixuuz

cixuuz commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

self-added: yes

  • Fetch pruning deletes operator-owned local tags (span=7e89de79d6c1)

Rebutted as NOT A DEFECT, by execution rather than reading. I built five fresh
repos, one per fetch form, each holding a local-only tag and a tag the remote had
deleted, and ran the forms against them on git 2.54:
--tags --prune-tags <remote> <branch> (the exact line at release_channel_pin.py:132)
leaves BOTH tags in place. So does --tags --prune-tags <remote>, and so does
--prune --tags --prune-tags <remote> <branch>. --tags defeats the pruning.
Only --prune --prune-tags with no --tags, and an explicit
+refs/tags/*:refs/tags/* under --prune, delete anything — and those delete the
local-only tag too, which is why this PR does not use them.
The stated trigger therefore cannot fire: no local tag is lost on Create or Advance.
The flag has still been REMOVED, because the same experiment showed it was a no-op
and this PR claimed otherwise (see span=735a0cf827f8) — but that is a false-claim
fix, not a data-loss fix, and the fetch was never able to delete an operator's tag.
This ruling covers findings that assert tag deletion from this additive fetch.

@cixuuz

cixuuz commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author
  • Release-channel placeholders lack a narrow layout (span=bf06a3b651f2)

Rebutted as disproportional, and the adjudicator reached the same conclusion
independently (DOWNGRADE F3, reason=disproportionate-remedy).
The placeholder is not an outlier: minWidth: 640 with that exact
gridTemplateColumns is the page-wide convention — the column header
(DevFleetPage.tsx:2112), every real fleet row (:2126), the sync log (:2212), the
detail panel (:2219) and the legacy toggle (:2277) all carry it. The placeholder was
written to match its siblings, which is why it reads the same.
Giving this one row type a narrow-first layout either contradicts that convention or
means making the whole table responsive, which is a redesign this PR did not set out
to do. The degradation is pan-to-see-it: content present, reachable, self-correcting,
no data loss.
This ruling covers narrow-viewport findings against the release-channel rows while
the surrounding table remains a fixed 640px-min layout; a finding about the TABLE's
responsiveness is a different, legitimate piece of work.

@cixuuz

cixuuz commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

self-added: yes

  • --prune-tags is passed without --prune, so tags deleted upstream are not pruned (span=735a0cf827f8)

Fixed, and this was the real defect in that line — not the data loss the other lane
read into it. Confirmed by execution: on git 2.54 the flag does nothing in this form,
and a tag the remote had deleted survived the fetch.
So the claim was false in three places, and all three are corrected rather than
softened: the flag is gone from the argv, the module docstring now states the fetch
is additive, and the spec section plus the PR body say a retracted release is a known
gap. The test that asserted the flag now asserts its ABSENCE, along with --prune.
Not fixed by adding --prune: the same experiment showed every pruning form also
deletes local-only tags the operator authored, and a pruned tag ref is in no reflog.
Retraction coverage worth having means fetching release tags into a private namespace
and resolving lanes there, which is named in the spec as the way to buy it.
This ruling covers findings about retracted releases staying resolvable: it is now a
stated limitation, not an unnoticed one.

@cixuuz

cixuuz commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

mechanism: removed

  • Subtraction — delete lane_of_worktree_name and its __all__ entry (span=5fbf21c17205)

Accepted and done. It had no callers: the payload publishes the worktree basename
per lane and the frontend consumes that, so nothing ever needed to parse a name back
into a lane. Deleted along with its __all__ entry and its three tests.
The naming test that remains asserts the thing that is actually load-bearing — that
one prefix rule lives on the backend only — rather than a round-trip through a
function nobody called.

@cixuuz

cixuuz commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

mechanism: removed

  • Subtraction — drop tag, oid, head_oid from the release_channels row (span=f0c155286b4b)

Accepted and done. All three are gone from the row, from the frontend interface and
from the test fixtures.
The row renders version || ref || lane, so those three were carried for a
diagnostic surface that does not exist. A field kept "in case someone wants it" is a
contract claim no consumer keeps, and it is exactly what makes the next reader think
the payload is richer than the UI.

@cixuuz

cixuuz commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

mechanism: removed

  • Subtraction — drop needs_provision and needs_rebuild with the spec sentence (span=a6e2ed2180bb)

Accepted and done. Both fields are gone from the two mutation responses, from the
frontend response types, from the tests and from the spec sentence that described
them.
The hazard they claimed to guard is real, so it did not simply get deleted with them:
after Advance the built artifacts under the tree are from the previous ref. That
warning now goes in the toast the operator is already reading. The row genuinely
cannot guard it — has_dist cannot tell a stale static/dist from a fresh one — so
a typed field nothing rendered was never going to be the guard.

@cixuuz

cixuuz commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author
  • needs_rebuild's comment claims a guard the frontend never reads (span=59bffcf9e656)

Fixed by removal, which is the option this item named. The field is gone, and so are
both prose claims — the comment in worktree_ops.py and the line in dev-fleet.md.
The stale-build hazard is now stated where it can act: the post-Advance toast tells
the operator to re-provision. The spec says why that is the right place, namely that
the row cannot distinguish a stale build from a fresh one.

@cixuuz

cixuuz commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author
  • Item 9 — release_channels row fields and the new module's exports have zero consumers (span=b5abfac1b8bd)

Accepted in full; the individual subtractions are answered at span=f0c155286b4b and
span=5fbf21c17205. Recording the shape of the mistake here because it is the useful
part: three fields and one function were written for readers I assumed would want
them, and the row only ever rendered version || ref || lane.
Everything remaining in the row now has a named reader, and the spec says so field by
field, so the next round can check the claim instead of trusting it.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no
mechanism: success scene fixed to an at-tip, unprovisioned row

  • Shot 10 shows Create delivering a stale pin at a missing control (span=199baddd6c1b)

Fixed — you read the frame correctly, and the frame was wrong, not the code. The create=ok path reused the adopted fixture (behind badge, has_dist: true), so the toast pointed at a Provision button the scene never rendered. The Create scenes now start from a placeholder whose version equals the tip and, on success, flip to the row Create actually produces: at the tip (bare 0.5.3, ok variant), not built, with the Provision button on the row and Needs Provision at 1. The runner asserts the toast text, the bare badge, the absence of latest, and exactly one Provision button. Frame 10 re-shot.

The evidence gaps your BLOCK named are closed in the same push: frame 12 is the unreadable-HEAD row (one row, no badge, no Create, the resolver notice beneath), and frame 13 is the release row's menu open, showing the ordinary controls with Rebase absent.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Create read correctly "as a guess", with a pause over cost (span=5bf729651718)

Deferred to #12354, not fixed here. Stating Create's disk cost needs a measured figure — the main checkout's working-tree size, or the last created worktree's — and a decision about whether every worktree-creating control in Dev Fleet should say it, not only this one. That is a new mechanism outside this PR's intent; the round-31 retrospective ruled it a follow-up so this round does not open another wording cycle on the placeholder row. The issue carries the blind-read quote and an acceptance check.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Differentiate release_channel_unresolved on an adopted row (span=a028b200c7fa)

Accepted as right, deferred to #12355. channelErrorFor already tells the adopted case from the placeholder case in the derivation, so this is a message split ("Could not check for newer stable releases: …" on the adopted row), and cheap — but it is a fourth differentiated string in a PR whose last three rounds were wording rounds, and the retrospective's ruling is to stop growing the copy here. The issue names the sentence and asks the harness to assert frames 06 and 07 differ.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Mutable git config can bypass checkout probes (span=9dfffee0bb1f)

Upheld as real and deferred to #12342, unchanged from the round-30 ruling on the same residual. The probe runs inside the populate's own gitdir context, inside the mutation lock, immediately before reset --hard; what remains is the gap between two git spawns during which repository config is writable by anything with the agent's filesystem access. No further probe closes that — the mechanism is probe-then-act — and your own fix line names the actual remedy: a hermetic populate that consults no repository-supplied config. That is a design change across the six probe sites #10691 tracks, with acceptance criteria written into #12342 (a driver planted after the probe does not execute). The round-28 and round-31 retrospectives both classed it as follow-up work rather than a further patch to this PR.

This finding is security-fenced, so no rebuttal of mine clears it. The maintainer accepting the deferral posts the override on the current head; I will not.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: yes
mechanism: tree's own release resolved independently of tip resolution

  • if not head or not tip: return out skips the detached HEAD's release lookup (span=7f589e736759)

Fixed — a real misreport, and a good catch. worktree_state returned before _release_at_head whenever the tip had not resolved, and fleet_state only published version when the resolver succeeded, so every resolver failure relabelled a checkout sitting on a published release as "not on a release" beside the error notice. The tree's release is read from the local mirror with no network call and is a fact about the tree, not the channel: it is now resolved and published regardless, with at_tip left null (no tip to compare) and the badge tooltip saying the tip could not be resolved. Two tests pin it, one at each layer, and both fail on the previous early return. The spec's row-contract paragraph now states the independence. Frame 07 of the harness already showed this state; the backend can now produce it.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Mutable git config can redirect the checkout after validation (span=9dfffee0bb1f)

Upheld as real and deferred to #12342, unchanged from the round-30 and round-32 rulings on the same residual. The probe runs inside the populate's own gitdir context, inside the mutation lock, immediately before reset --hard; what remains is the gap between two git spawns during which repository config is writable by anything with the agent's filesystem access. No further probe closes that — the mechanism is probe-then-act — and your own fix line names the actual remedy: a hermetic populate that consults no repository-supplied config. That is a design change across the six probe sites #10691 tracks, with acceptance criteria written into #12342 (a driver planted after the probe does not execute). The round-28 and round-31 retrospectives both classed it as follow-up work rather than a further patch to this PR.

This finding is security-fenced, so no rebuttal of mine clears it. The maintainer accepting the deferral posts the override on the current head; I will not.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: yes
mechanism: feature-map row completed (full handler path, fleet_state owner, GET fleet endpoint)

  • Feature map omits the row-state owner and endpoint (span=2f6082500a24)

Fixed as asked. The row now names src/kiro_crew/apps/builtins/dev_fleet/http_api.py with the same prefix its sibling Dev Fleet rows use, adds fleet_state.py (row state) beside the resolve and create owners, and lists GET /apps/dev-fleet/api/fleet (row) ahead of the Create POST. Adjudication flagged it cosmetic because the fleet owner is one row up; the fix is one table cell, so it was cheaper to make the row self-sufficient than to argue the point. check_feature_map.py against origin/main passes.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Mutable git config can redirect or inject the checkout after validation (span=9dfffee0bb1f)

Upheld as real and deferred to #12342, unchanged from the round-30, round-32 and round-33 rulings on the same residual. The probe runs inside the populate's own gitdir context, inside the mutation lock, immediately before reset --hard; what remains is the gap between two git spawns during which repository config is writable by anything with the agent's filesystem access. No further probe closes that — the mechanism is probe-then-act — and your own fix line names the actual remedy: a hermetic populate that consults no repository-supplied config. That is a design change across the six probe sites #10691 tracks, with acceptance criteria written into #12342 (a driver planted after the probe does not execute). The round-28 and round-31 retrospectives both classed it as follow-up work rather than a further patch to this PR.

This finding is security-fenced, so no rebuttal of mine clears it. The maintainer accepting the deferral posts the override on the current head; I will not.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • ready pill above "could not be resolved" (span=aeb386c17ee7)

Accepted as right and deferred to #12355, where it is now the first item: your suggested opening ("Worktree is usable — the release check failed: …") is the adopted-row notice split that issue already proposes, extended to the unreadable-HEAD row frame 12 shows. Not this round: the round-31 retrospective ruled that this PR stops growing its copy after three wording rounds, and the state is already honest (the pill describes the checkout, the notice describes the channel lookup) — the gap is that the notice does not say so in one breath. The issue carries the acceptance check that the harness frames assert the notice opens with what still works.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • "rename or remove it to free it" names no visible control (span=0ea51ab58a58)

Not changed this round, by a ruling I will defend: the round-31 retrospective froze this sentence after three wordings drew three different misreads, because each new string re-opened the loop without converging. Your point stands — Prune merged is the one on-screen control that frees the name, and it is named only in the tooltip — so it is recorded on #12355 alongside the two sibling notice-copy items, where the sentence can be revisited once as a set rather than patched a fifth time here. The row is not a dead end: the tooltip names Prune merged and the shell commands, and the state only arises when an operator has themselves created a branch under the reserved name.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Create-failure notice relays git's remedy verbatim (span=ed9354bd59cb)

Accepted, deferred to #12355 as its second item. The notice quotes git's message as the cause on purpose (it is what the operator needs to diagnose), but you are right that git's remedy ("use 'add -f' … or 'prune'") names commands this screen does not offer and collides with the Prune merged button. The fix is to lead with the screen's own remedy (retry via Remove / Create, or Ask the agent) before the quoted text — the same framing the badge tooltips use — and it belongs in the one pass that reworks all three failure notices together rather than in this PR's fourth copy round. Ask the agent absorbs it meanwhile, as you note.

Dev Fleet manages git checkouts, and a git checkout has no release channel —
`platform/update_capability.py` says so outright: "Only the wheel command
carries a channel. A git checkout follows its remote." That leaves no way to
run what stable actually shipped next to unreleased work.

Adds ONE detached worktree pinned to the stable channel, named
`release-channel-stable` as a sibling of the primary checkout, appearing as an
ordinary fleet row that pods and Make Live already drive.

Why not a pin on the primary checkout: sync fast-forwards it (`merge --ff-only`)
and refuses unless HEAD is literally `BASE_BRANCH`. A stable tag is normally
BEHIND main, so pinning that checkout could only work by detaching its HEAD —
which the sync guard rejects, and which repoints every origin/main comparison on
the row — or by resetting main backwards, which destroys work.

Not coupled to the update channel: nothing reads or writes
`$KIROCREW_HOME/channel`. That file says which lane the user's install FOLLOWS
for updates; a pin here says which ref a worktree SITS ON. There is one channel
and it is a single `CHANNEL = "stable"` constant, not a lane vocabulary — an
unpublished lane is a state of that channel, never a second kind of row.

Resolution takes the newest `vX.Y.Z` in SEMVER-DESCENDING order. Tag creation
date is not the ordering: a retagged or backfilled release publishes out of
order, and "newest release" is a claim about version precedence rather than
about when someone pushed the tag.

Resolution is sourced from a private pruned tag mirror
(`refs/dev-fleet/release-tags/`), fetched under a checked refspec, so a local tag
cannot decide what gets checked out — a forged `v9.9.9` in the operator's own
clone resolves nothing. An `ls-remote` provenance check closes the window
between resolving a tag and checking it out, and `repo_supplied_filter` refuses
repo-configured content filters so a fetched repository cannot run its own code
during the checkout; both run inside `_GIT_MUTATION_LOCK`.

`release-channel-*` is reserved, so adoption requires the SHAPE (detached),
never the name — a user's branch checkout under that name keeps ordinary
controls and its ordinary behind-main count, and reports that it is not a
release worktree rather than being silently adopted.

Create only: there is no in-place mutation of a pin. A pinned tree that moved on
its own would shift under a pod being debugged, and an explicit Advance turned
out to be the mechanism forcing every unpleasant tradeoff around it, so moving a
pin is Remove followed by Create — two visible acts on the row that owns them.

Fleet payload gains `release_channel`, its own key rather than extra `worktrees`
rows: a channel with no worktree has no path, and every consumer of a worktrees
entry assumes one. On this row BEHIND measures distance from the CHANNEL TIP (the
behind-main figure is large by construction and names no action) and PR renders
as inapplicable rather than as the no-PR dash. Because the Behind column header
is one shared element above rows with two different denominators, it names both.

Adds `website/capture/devfleet-release-channel.{tsx,html}` and
`website/scripts/capture-devfleet-release-channel.mjs`, the committed harness
that renders the three row states — adopted, placeholder, reserved-name branch —
against the real page with `fetch` stubbed at the network seam.
@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Mutable git config can redirect or execute during checkout (span=9dfffee0bb1f)

Upheld as real and deferred to #12342, unchanged from the round-30 through round-34 rulings on the same residual. The probe runs inside the populate's own gitdir context, inside the mutation lock, immediately before reset --hard; what remains is the gap between two git spawns during which repository config is writable by anything with the agent's filesystem access. No further probe closes that — the mechanism is probe-then-act — and your own fix line names the actual remedy: a hermetic populate that consults no repository-supplied config. That is a design change across the six probe sites #10691 tracks, with acceptance criteria written into #12342 (a driver planted after the probe does not execute). The round-28 and round-31 retrospectives both classed it as follow-up work rather than a further patch to this PR.

This finding is security-fenced, so no rebuttal of mine clears it. The maintainer accepting the deferral posts the override on the current head; I will not.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: yes
mechanism: lane-keyed Create-error map collapsed to one value; lane parameters removed

  • Item 9 — one consumer, generalized (span=e890f8e5e536)

Fixed by deletion. The backend publishes exactly one release_channel whose lane is a constant, so releaseChannelCreateError is now a single string | null, createReleaseChannel() and the dismiss path take no lane, and the dismissReleaseChannelCreateError helper is gone (its only job was deleting a key from a one-key map). The notice still carries rc.lane in its test id because that is the row's name on screen, not a lookup key. 34 tests in the release-channel file still pass unchanged, which is itself the evidence the parameter carried no information.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Unreadable-HEAD row keeps its ready pill above the resolver notice (span=df8f5d15ca56)

Accepted and deferred to #12355 (item 1 there, written from your round-34 wording; this round's re-read adds that the pill can steer an operator into podding a tree whose HEAD could not be read, which the issue now quotes). Not this round: the round-31 retrospective ruled that this PR stops growing its copy, and the three notice states you name here and below are one fix class — a failure notice that does not lead with what still works and what to do on this screen — that should be reworked together. The ready pill is the worktree's own has_dist state and is true; what is missing is the notice saying so in the same breath.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • One opener, three failures (span=25917b3bedd0)

Accepted and deferred to #12355, whose proposal is exactly this split: on a placeholder the channel could not be resolved; on an adopted row the release check failed but the worktree is usable; on an unreadable-HEAD row the local tree, not the remote, is what broke. channelErrorFor already distinguishes the cases in the derivation, so this is three sentences replacing one, and it is scheduled as one pass with the sibling items rather than a fourth copy round here.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Failed-Create notice: git's "prune" reads as the toolbar's Prune merged (span=a33b5c9d1980)

Accepted and deferred to #12355 (item 2 there). You are right that a quoted git remedy naming prune beside a red Prune merged button is a collision worth removing; the fix is a plain next-step clause (retry via Remove / Create, or Ask the agent) ahead of the quoted git text, which is the same shape the sibling notices need. Ask the agent absorbs the case meanwhile.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Mutable git config can redirect or execute during checkout (span=9dfffee0bb1f)

Upheld as real and deferred to #12342, unchanged from the round-30 through round-35 rulings on the same residual. The probe runs inside the populate's own gitdir context, inside the mutation lock, immediately before reset --hard; what remains is the gap between two git spawns during which repository config is writable by anything with the agent's filesystem access. No further probe closes that — the mechanism is probe-then-act — and your own fix line names the actual remedy: a hermetic populate that consults no repository-supplied config. That is a design change across the six probe sites #10691 tracks, with acceptance criteria written into #12342 (a driver planted after the probe does not execute). The round-28 and round-31 retrospectives both classed it as follow-up work rather than a further patch to this PR.

This finding is security-fenced, so no rebuttal of mine clears it. The maintainer accepting the deferral posts the override on the current head; I will not.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Unreadable-worktree row keeps its ready pill above the notice (span=49e79fe178ac)

Accepted and deferred to #12355 (item 1), unchanged from the disposition on the previous two heads: the pill reports the worktree's own has_dist state and is true; the notice reports that the tree's git state could not be read. The fix is the notice leading with what that means for this row, and it is scheduled with the sibling notice-copy items as one pass rather than a fourth copy round in this PR (round-31 retrospective ruling).

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Reserved-name row: the how lives only in the tooltip (span=faea8d6db93e)

Not changed this round, per the round-31 retrospective's freeze after three wordings drew three different misreads. Your reading is recorded on #12355 alongside the sibling notice items, where the sentence will be revisited once as part of that set — promoting "Prune merged removes it once its PR merges" into the visible text is the leading candidate there. The state only arises when the operator has themselves created a branch under the reserved name, and the tooltip names Prune merged and the shell commands meanwhile.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • Placeholder promise differs between resolved and unpublished (span=81c28615eb2a)

Accepted and deferred to #12355 as its third item. The two strings describe genuinely different states — one where the newest release is known and named, one where nothing has been fetched yet — but you are right that both should name the same act; "Create checks out the newest release, 0.5.0" does that and keeps the number. It joins the one copy pass rather than landing here under the freeze.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

self-added: no

  • File the deferred detached-tree abandonment policy as a tracked issue (span=77a201d78609)

Already tracked: #10692 ("a detached worktree never ages into the empty verdict, so hand-detached trees accumulate") is the issue for exactly the cost worktree_ops.py accepts at the _prunable branch-check, filed from this PR's round-28 review and linked under Related Issues in the description with a one-line summary. Nothing further to file.

@cixuuz

cixuuz commented Sep 20, 2026

Copy link
Copy Markdown
Contributor Author

Round 36 — review-ready except one human-only gate

Head 4daa88559009b9f3791ac479d4eb6869810b4ac2 (single commit on current main, mergeable).

Lane / gate State
CI checks 91 / 93 green; the two reds are the GPT lane and PR Readiness, which inherits it
Design Review PASS
First Principles Review PASS
Opus 4.8 Review PASS (no findings)
UX Review CONCERNS (advisory) — 3 notice-copy items, all dispositioned and tracked on #12355
Security Scope Review PASS
GPT 5.6 Review 🔴 one security-fenced finding, span 9dfffee0bb1f — see below
Disposition rule clean (every whole-design item on every head answered)

The one open finding

worktree_ops.py Create: the content-filter / core.worktree probe and the reset --hard populate are two git spawns inside one lock, and repository config stays writable between them. The probe already runs in the populate's own gitdir context (round 29), so nothing it missed can run; what remains is the sub-millisecond rewrite window the code documents as its residual. GPT has raised this on six consecutive heads; Opus adjudication upholds it each time because it is fenced (annotate-only), not because a rarity argument fails on the merits.

Every mitigation this PR can add narrows the gap; none removes it, because the mechanism is probe-then-act. What removes it is a hermetic populate that consults no repository-supplied config, which is a design change across the six probe sites #10691 tracks. That is filed as #12342 with acceptance criteria (a driver planted after the probe does not execute), and both the round-28 and round-31 retrospectives classed it as follow-up work rather than a further patch here.

What a maintainer needs to do

If the deferral to #12342 is acceptable, post on this PR:

/ai-review override gpt 4daa88559009b9f3791ac479d4eb6869810b4ac2: probe/populate config-rewrite TOCTOU deferred to #12342 (hermetic checkout)

Then PR Readiness re-evaluates green and the PR is ready for the human review that branch protection requires. Auto-merge is not armed and will not be by the author's agent.

If the deferral is not acceptable, the alternative is to scope the hermetic checkout into this PR, which reopens the module the last eight rounds converged and is best done as its own PR against the design in #12342.

Follow-ups filed from this review (none block merge)

#12342 hermetic checkout · #12353 refresher --tags fetch · #12354 Create disk-cost hint · #12355 failure-notice copy (4 items) · #10692 detached-tree abandonment · #10691 probe-site consolidation · #10459 build provenance

@dwu96

dwu96 commented Sep 24, 2026

Copy link
Copy Markdown
Contributor

🤖 Kiro Crew [operator: dwu96#8c08bee0]: This PR has been inactive for 7+ days. I reviewed the blockers but they require your input:

  • The one blocking readiness item is a decision, not a fix. GPT 5.6 still holds 4daa8855 at 🔴 on the security-fenced finding at worktree_ops.py:3077 (the sub-millisecond probe→reset --hard config race), and the Opus adjudicator UPHOLD-FENCED it, so no lane will clear it on its own. You upheld it as real and deferred it to dev-fleet: hermetic release-channel checkout — populate must not consult repo-supplied config (probe/populate TOCTOU) #12342 — a hermetic checkout that consults no repository-supplied config, across the six probe sites in config-filter probe: six divergent spellings across five areas, and md_notebook's boolean read misses four git spellings #10691. That leaves exactly two ways forward and both are yours: land the hermetic populate in this PR (a design change this PR deliberately scoped out), or have a repository writer post /ai-review override gpt <head sha>: <reason> to accept the documented residual. I will not pick between them, and I will not change the design direction of your PR to silence a lane.
  • main has moved past your round-36 "mergeable" state — it is now CONFLICTING. Four files: website/scripts/check-bundle-size.mjs plus website/src/i18n/en.context.json, locales/en-XA.json and locales/en.manual.json. The three i18n ones are ordinary catalogue collisions, but the bundle-size ceiling is not a pick — both sides raised it, and the merged number has to be re-measured against the 5% convention with your 35 KB of catalogue copy in it. Whoever resolves it owns that measurement.
  • Scope. At ~6.9k added lines introducing a new subsystem (release_channel_pin.py, the Create mutation, its provenance and filter probes), this is past the surface an automated drive should reason about safely — so even with the conflict resolved I would not take it green unattended.

Everything else reads healthy: Design, First Principles, Opus 4.8 and Security Scope all PASS, UX is advisory CONCERNS with its three copy items tracked on #12355, and 91/93 checks are green. It is the one gate above that is holding the PR.

When you've addressed these, the pipeline will re-assess on its next cycle.

@bolichen97

Copy link
Copy Markdown
Contributor

Closing in favour of #12356, which implements the same change.

Evidence. 38 of 40 files are shared (21 after excluding files that 20+ open PRs touch), covering the same dev-fleet channel-pin mechanism: fleet_state.py, http_api.py, app.json and the module spec.

Why this one and not #12356. #12356 is the later and more complete cut of the same mechanism.

This is not a judgement on the work -- the two changes were written independently and this one is not the weaker of the pair, it is the one that does not need to land twice. If you disagree, or if #12356 turns out to miss something this branch handles, say so and I will reopen this.

From a full relationship audit of every open PR against main (baseline a992d5cda5). Overlap was measured with git diff against each branch's own merge base, and re-measured after excluding files that 20+ open PRs touch, so shared locale and lockfile edits could not inflate it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge conflict Branch has merge conflicts with its base — author must resolve before merge needs-author-decision PR blocked on author input

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Dev Fleet: a retracted release stays resolvable as the stable channel tip

5 participants