Skip to content

fix(artifacts): refuse stale content writes with 409 instead of silently overwriting - #14075

Merged
KiroCrewCaptain merged 1 commit into
kirodotdev:mainfrom
peterhieuvu:fix/artifact-stale-write-409
Oct 8, 2026
Merged

KiroCrewCaptain merged 1 commit into
kirodotdev:mainfrom
peterhieuvu:fix/artifact-stale-write-409

Conversation

@peterhieuvu

@peterhieuvu peterhieuvu commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: Stop a save from a stale editor silently overwriting newer artifact content; refuse it with a 409 and keep the draft.

Two editors on the same artifact silently overwrite each other. Saving from a stale dashboard tab, or a user saving over an agent's newer edit, replaces the live content with no warning, because PATCH /api/artifacts/{slug} writes unconditionally (#7751).

Why it matters

The person whose work is lost never finds out. Silent saves don't bump version, so nothing in the UI shows the overwrite happened.

Not a goal

What changed (motivation → approach → change)

A save now carries the content token it started from. If another save landed since, the save is refused with a 409 and the draft is kept.

Piece Change
Store (src/kiro_crew/artifacts.py, artifact_store/model.py, artifact_store/records.py) Store-backed artifacts carry a content_token stored in meta.json. update(expected_token=) compares it under the store lock before writing and raises ArtifactConflictError on a mismatch.
Handler (dashboard/handlers/artifacts.py) A stale write returns 409 {error, code: "artifact_conflict", current_token}. A malformed token returns 400. The detail read gives an artifact saved before this change its token, and it runs off the event loop, as do the events and delete reads.
Page (ArtifactDetailPage.tsx, api/client/artifacts.ts, types/index.ts) The token is fixed when editing starts. On 409 the page keeps the draft and shows a "Not saved." notice with a link that opens the newer version in a new tab. Save becomes "Save — overwrite newer content", and only a click on that button sends the 409's fresh token. Cmd+S, Cmd+Shift+S, Snapshot and the upstream banner's pull, overwrite and snapshot all keep the base token and stay refused; a refused banner action shows only the notice. The notice and the button's tooltip name the button click as the only way to overwrite. A save is skipped while an earlier save or a banner flush is still in flight, and the banner's actions are disabled during a save, so a repeated save cannot race the one in flight and draw a false 409. A save that finishes after the page moved to another artifact, or after a new edit started, leaves that editor's token and notice alone.
Strings, spec Five new strings in every website/src/i18n locale catalog. The PATCH row in docs/system-specs/modules/artifacts.md documents the token.

The token is 256 random bits, replaced on every content write. Nothing in it comes from the content, so a copy of meta.json reveals nothing about text the HTTP layer redacts. The new token is saved before the new content, so a save that fails between the two files can cause a false 409 but cannot let a stale save through. An artifact saved before this change gets a token when the dashboard opens it. If that write fails, the read returns the content without a token, and that tab's next save is last-write-wins. Every other read returns the stored token, or none, and writes nothing. A malformed stored token is replaced, with a warning, instead of making the artifact unreadable.

Omitting the token keeps today's last-write-wins behavior, so MCP, revert and other callers are unchanged. File-backed artifacts get no token and ignore one. Guarding their source files needs a maintainer decision, tracked in #14039.

Backwards compatibility

None. The token is optional, and a client that ignores it behaves as before.

Tests

  • test/test_artifacts.py: matching, stale and omitted tokens; metadata-only, snapshot-only and silent saves; a fresh token from every content writer, identical content included; the token persisted and served only beside current content, and a missing or corrupt one replaced rather than fatal; the dashboard's read giving an untokened artifact a token while a plain read writes nothing; a token-assigning read whose write fails returning the content with no token, and the next one getting a working one; a save or a draft settle that fails after its content write still refusing the stale token; tokens surviving a new store instance; file-backed artifacts and versioned reads carrying no token.
  • test/test_artifacts_handlers.py: the 409 body and code, 400 on a malformed token, a matching token saving and returning the next one, the detail response carrying the stored token and giving an untokened artifact one, and the detail, events and delete handlers reading off the event loop. The token tests in both files draw tokens from a counter, so no comparison depends on chance.
  • test/test_artifacts_refactor_{store,projection}_contract.py: the surface pins list content_token in meta.json and on a current read, and the ArtifactConflictError export.
  • website/src/test/ArtifactDetailPage.saveConflict.test.tsx: the token is sent, a 409 keeps the draft and shows the notice, the overwrite sends the fresh token, and after a 409 Snapshot, Cmd+S, Cmd+Shift+S and a banner pull all keep the base token, with the pull showing only the notice. A save repeated while one is in flight, or made during a banner flush, sends no second write, and the banner is disabled during a save. A save on one artifact that finishes after the page moved to another, whether it succeeded or got a 409, leaves the new editor's token and notice alone. Each fails with the guard it covers removed.

Manual verification

Run on a private local gateway against e6b98a3484, a commit of this PR whose token was an HMAC of the content instead of a stored random value. The API, the responses and the page are the same on this head. An artifact saved before content tokens existed opened normally and was guarded from its first read. With a draft open in one tab, a second tab saved a newer version; the first tab's save was then refused with the notice shown, the draft stayed, Save changed to the overwrite action, and the server still held the second tab's content. The stored token itself and the skipped repeat save are covered by the tests above.

Screenshots / video

Stale save refused: "Not saved." notice with a link to the newer version, draft kept, Save relabelled as the overwrite

Pull latest on a fork with a stale draft: the flush is refused, only the "Not saved." notice shows, the pull does not run and the draft is kept

The second is from an isolated capture of the real page with the API stubbed, since a stock gateway has no publish provider to show the fork banner.

Committed under temp-screenshots/ (fork PR, no --attach).

Related Issues

Store-backed half of #7751. The file-backed case (external writes to source_path) moves to #14039, which needs a maintainer decision. This replaces the core of #7818.

Fixes #7751

Pattern harvest

Rule candidate: review-prompt
Pattern: a read-modify-write endpoint with no base token (last write wins across windows and actors)

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)
  • 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

@peterhieuvu
peterhieuvu requested review from a team and krishdhasmana September 26, 2026 01:30
@github-actions github-actions Bot added fork Pull request from a fork (external contributor) readiness: action required A blocking check or review needs attention labels Sep 26, 2026
@peterhieuvu

Copy link
Copy Markdown
Contributor Author

Intent: Stop a stale save from silently overwriting newer content on store-backed artifacts: a save carries the content token it started from, and a mismatch is refused with a 409 while the editor keeps the draft.
Not a goal: Guarding writes to a file-backed artifact's source file (#14039), making the conflict token survive a gateway restart, or hardening beyond the 409 path. Findings in those areas are deferred to #14039, not fixed here.

@github-actions

github-actions Bot commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5, fork) — 🟡 CONCERNS

UX-level review of df55b835635da6995317e3ec920ae544b990661b via the fork AI-review pipeline — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

UX-Verdict: CONCERNS

Two different "newer version"s appear on screen at once. Nobody new to the page has read this notice or the relabelled Save button yet.

Watch

  • Two "newer version"s, one link. In attachment-01.png (stale-pull-409) the fork banner says "a newer version is available in the remote copy (v4)". The notice directly under it offers "Open the newer version in a new tab". That link (href={/artifacts/${slug}}) opens the local live content, not the remote v4. A user who wants to compare against the remote clicks it and lands on the wrong document. Severity: medium. It only happens on forked artifacts, but the wrong pick is likely every time. Fix: rename the link to "Open the current saved version in a new tab".

  • The overwrite button looks like a normal Save. "Save — overwrite newer content" stays in the primary accent fill, in the same spot as Save, so it looks like the button the user clicks every day (both screenshots). A user who got used to clicking Save can replace someone else's newer work with one click. Severity: medium. It happens rarely, but the overwrite can't be undone. Fix: give the button the danger tone while saveConflict is set.

  • The notice names a cause the guard doesn't catch. save_conflict_changed_since_read lists "an external edit" as a possible cause. The PR's "Not a goal" says edits to current.html made outside the store don't change the token, so they never trigger this notice. The copy teaches users that outside edits are caught, when the guard really covers other windows and agents only. Severity: low. Fix: "Content changed since you loaded it — another window or an agent saved a newer version."

  • Not shown in any screenshot:

    • the tooltip text save_overwrite_newer_content_title
    • the banner's "Pull latest", "Overwrite" and "Snapshot" buttons greyed out (busy) while a save is in flight

    Both are brief or hover-only states. Add one still of each if you can.

Suggestions

  • save_conflict_changed_since_read: change "clicking the Save button again will overwrite" to "Save — overwrite newer content replaces it with your draft". The notice then names the exact button label, and the line also tells Cmd+S users why their shortcut is still refused.

[UX-REVIEWED] df55b83

Description read

[DESCRIPTION-READ] f54a75f6bea4cceeb7f976fa52f53040e8471e368ac7b7e34528e07f4328db74

That sha256 names everything this verdict read: the PR description, plus the 5 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5, fork) — ✅ PASS

Design-level review of df55b835635da6995317e3ec920ae544b990661b via the fork AI-review pipeline — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

Design-Verdict: PASS

Nothing to check.

[DESIGN-REVIEWED] df55b83

Description read

[DESCRIPTION-READ] 05323befc00371cd46a414e876c9da39f736fd767bdd6a1785378a9e13fb4955

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

GPT 6.1 Review (fork) — ✅ no blocking findings

Reviewed df55b835635da6995317e3ec920ae544b990661b via the fork AI-review pipeline; updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] df55b83

@github-actions

github-actions Bot commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5, fork) — ✅ PASS

Premise-level review of df55b835635da6995317e3ec920ae544b990661b via the fork AI-review pipeline — 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

Check before merge: moving the events and delete reads off the event loop does nothing for the 409 fix. Confirm that change belongs in this PR.

Not justified as shipped

  • Item 8 — rides along: the description says "it runs off the event loop, as do the events and delete reads". Only the detail read writes a token, so only that read needs to move off the loop.

What this change ships

Inventory (10 items) — 9 justified

Intent: stop a save from a stale tab or editor silently replacing newer artifact content (#7751). This is a FIX.

  1. A dashboard save based on stale content is refused with 409, and the draft is kept — justified
  2. A "Not saved." notice appears with a link that opens the newer version in a new tab — justified
  3. After a conflict the Save button becomes "Save — overwrite newer content", and only a click on it overwrites — justified
  4. After a 409, Cmd+S, Cmd+Shift+S, Snapshot and the banner's pull, overwrite and snapshot are still refused — justified
  5. A repeated save is skipped while one is in flight, and the banner is disabled during a save — justified
  6. Each artifact now stores a random content_token; an older artifact gets one when its detail page opens — justified
  7. PATCH accepts an optional expected_token: a stale one gets a 409 with current_token, a malformed one gets a 400 — justified
  8. The events and delete reads now run off the event loop — rides along: not needed for the fix
  9. A save that finishes after the page has moved to another artifact leaves the new editor untouched — justified
  10. A refused banner action shows only the page's conflict notice, not a second error — justified

[FIRST-PRINCIPLES-REVIEWED] df55b83

Description read

[DESCRIPTION-READ] bfa323c2a9117829af7d257af484c182bd36668db8a359bfd2563dffca4b6983

That sha256 names the PR description this verdict read. Recompute it with .github/scripts/pr-description-capture.sh; if it differs, the description changed after this verdict was formed and any finding drawn from the description is unproven.

@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 26, 2026
@github-actions

github-actions Bot commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

Opus 5.5 Review (fork) — ✅ no blocking findings

Reviewed df55b835635da6995317e3ec920ae544b990661b via the fork AI-review pipeline; updated in place on each push.

Review details

No findings.

FINDING — website/src/pages/ArtifactDetailPage.tsx:2003 — after a 409 sets saveConflict, the version selector's onChange exits edit mode with setEditing(false) but never calls setSaveConflict(false), so a later unrelated failure (for example handleSnapshotLive or handleRevert hitting a network error) shows up under save_conflict_title with the "open the newer version in a new tab" footer → Fix: call setSaveConflict(false) (and clear overwriteTokenRef.current) in that guardCommentDraft callback, the same way cancelEditing does.

[OPUS-REVIEWED] df55b83

@github-actions github-actions Bot added the merge conflict Branch has merge conflicts with its base — author must resolve before merge label Sep 28, 2026
@peterhieuvu
peterhieuvu requested a review from a team as a code owner September 29, 2026 00:39
@peterhieuvu

Copy link
Copy Markdown
Contributor Author

Round 1 disposition, head 434cc7137e:

Lane Finding Disposition
GPT (blocking) After a 409, a pull or overwrite from the upstream banner flushed on the fresh token and overwrote the other writer Fixed. Only the explicit "Save — overwrite newer content" sends the 409's token; banner flushes keep the base token and stay refused. New test fails on the previous page.
First Principles The in-memory process key adds nothing beyond the unserialized per-artifact salt Fixed. The HMAC is keyed by the persisted salt; no process key. This also removes the false 409 after a restart (Design).
Design, First Principles A malformed salt made the artifact unreadable Fixed. A missing or malformed salt is replaced on first read with a warning.
First Principles version in the 409 body has no reader Removed.
First Principles Hoisting the event_type check is outside this fix Reverted to main's placement; the PR no longer has a breaking change.
UX Notice titled "Save failed:"; overwrite-or-cancel is a blind choice Fixed. Titled "Not saved." with a link that opens the newer version in a new tab.
Opus Strings added directly to en.json would be lost on the next i18n converter run Not changed. The converter is a one-time migration tool: re-running it on a converted tree refuses to overwrite, and --merge keeps hand-added keys.

The screenshot is committed under temp-screenshots/ (fork PR, #13201 path). Test reds on the previous head (test_spawn_approval_channel_delivery_2381, test_sandbox_protected_name_holds) fail identically on a clean upstream/main; test_aws_control_backup is a known concurrency flake; Coverage Gate followed those shards.

@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 29, 2026
@peterhieuvu
peterhieuvu force-pushed the fix/artifact-stale-write-409 branch from 434cc71 to a3e2ce4 Compare September 29, 2026 17:57
@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed merge conflict Branch has merge conflicts with its base — author must resolve before merge readiness: checking Automated validation is still running labels Sep 29, 2026
@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 Oct 8, 2026
…tly overwriting

- Store-backed reads carry a content_token; update(expected_token=) compares
  it under the store lock and raises ArtifactConflictError on a stale write.
- The token is 256 random bits stored in meta.json and replaced on every
  content write, so it reveals nothing about the content it guards. The new
  token is saved before the new content, so a write that fails between the
  two files can only refuse an earlier read, never admit it.
- The dashboard's detail read, which runs off the event loop, gives an
  artifact saved before tokens existed its token; when that meta.json write
  fails, it returns the content without a token. Other reads write nothing.
- The detail page pins the token at edit start and keeps the draft on a 409;
  only the relabelled Save button sends the fresh token to overwrite.
- A save is skipped while another token write is on the wire, and the fork
  banner's actions are disabled during a save, so a repeated save cannot
  draw a false 409. A write that finishes after the page moved to another
  artifact or started a new edit leaves that editor's token and state alone.
- The fork banner's pull/overwrite/snapshot leave a refused flush to the
  page's localized conflict notice.
- The detail, events and delete handlers run their current read off the
  event loop.
@peterhieuvu
peterhieuvu force-pushed the fix/artifact-stale-write-409 branch from f04c32c to df55b83 Compare October 8, 2026 01:43
@peterhieuvu

Copy link
Copy Markdown
Contributor Author

self-added: yes
mechanism: editor token refs advanced by a save's completion

  • fixed span=2f715e40b5e4 A departing artifact's save can clear the next editor's concurrency token

Fixed in df55b83. handleSave and flushLiveEdits capture an edit generation before their await; the slug reset and startEditing advance it. A completion from an earlier artifact or edit session does not touch the current editor's tokens, conflict state or edit mode. Tests: a late tokenless save from another artifact does not clear the current edit token, a late 409 from another artifact does not arm a conflict in the current editor.

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=275f259054d5 A refused banner action reports the wrong action

Kept. A refused banner action runs no pull, overwrite or snapshot: its first step, saving the draft, is refused, so nothing on the server changes and the draft stays in the editor. The notice says the draft was not saved and names the one way to overwrite. Naming each action means three new strings in all 13 locale catalogs and two new screenshots, for feedback beyond this PR's goal.

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=11c5e8f235d2 A repeated save gives no sign it was refused

Kept. The notice from the first refusal stays on screen and says why the save was refused and how to overwrite. A repeated Cmd+S or Snapshot is refused for the same reason and changes nothing on the server or in the draft. Re-flashing the notice on every press is a feedback refinement beyond this PR's goal. The same point was answered on e6b98a3 and 38cbeca.

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=02d050f1f6ae The overwrite looks like a routine save

Kept. The overwrite happens only when the user clicks a button labelled "Save — overwrite newer content", below a notice that says the content changed and offers to open the newer version in a new tab. A danger tone on that button is a reasonable follow-up, but it is visual polish beyond this PR's goal and changes both screenshots.

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=314ec7b963f6 Drop "or an external edit" from the conflict notice

Kept. Writers outside the dashboard and agents still go through the gateway and replace the stored token (the CLI proxies the gateway HTTP API), so they can raise this notice, and "an external edit" names them. Only a write that bypasses the store, a hand edit of the artifact's internal current.html, does not, and users do not edit that file. Rewording means editing all 13 locale catalogs and recapturing both screenshots.

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=5a9939edf357 Name the button in the conflict notice

Kept. After a 409 the relabelled Save is the only control that overwrites, so "the Save button" names it. Quoting its full label means editing the sentence in all 13 locale catalogs and recapturing both screenshots, for wording only. The same suggestion was answered on 85d2d06, e6b98a3 and 38cbeca.

@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 Oct 8, 2026
@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=86af179412ff Two "newer version"s, one link

Kept. The notice's link opens this artifact's current content, the version whose save refused the draft; the fork banner's "newer version" is the remote copy. The two only appear together on a fork with a remote update pending, and both lines name what they act on. Relabelling the link means editing all 13 locale catalogs and recapturing both screenshots, for wording only.

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=749231a86cbf The overwrite button looks like a normal Save

Kept. The overwrite happens only on a click of a button labelled "Save — overwrite newer content", below a notice that says the content changed and offers the newer version in a new tab. A danger tone is reasonable polish for a follow-up; it changes both screenshots and is not needed to refuse a stale save. Answered on f04c32c.

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=ed0a6e020fe1 The notice names a cause the guard doesn't catch

Kept. Writers outside the dashboard and agents still go through the gateway and replace the stored token (the CLI proxies the gateway HTTP API), so they raise this notice, and "an external edit" names them. Only a write that bypasses the store, a hand edit of the artifact's internal current.html, does not, and users do not edit that file. Answered on f04c32c.

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=2c662f02d209 Not shown in any screenshot

Kept. The two screenshots show the two states this PR adds a screen for: a refused save, and a refused pull on a fork. The tooltip and the banner's disabled state are not new screens. The disabled banner is covered by the component test "the fork banner is disabled while a save is on the wire".

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=f7fde4e11da3 The tooltip text is not shown in a screenshot

Kept. The tooltip appears on hover over the relabelled button and changes no layout; its text is in the diff, in save_overwrite_newer_content_title in every locale catalog. A hover screenshot adds no evidence the catalogs do not already show.

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=ab088d2a8f83 The banner's buttons greyed out during a save are not shown

Kept. The disabled state lasts one request and reuses the banner's existing busy styling, so it adds no new look. The component test "the fork banner is disabled while a save is on the wire" asserts it.

@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • rebutted span=06024f385c3b Name the exact button label in the conflict notice

Kept. After a 409 the relabelled Save is the only control that overwrites, so "the Save button" names it. Quoting the full label means editing the sentence in all 13 locale catalogs and recapturing both screenshots, for wording only. The same suggestion was answered on 85d2d06, e6b98a3, 38cbeca and f04c32c.

@github-actions github-actions Bot added readiness: passed Eligible automated validation passed for the current revision and removed readiness: checking Automated validation is still running labels Oct 8, 2026
@KiroCrewCaptain
KiroCrewCaptain enabled auto-merge (squash) October 8, 2026 04:21

@iamwhatever iamwhatever left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This PR fixes #7751, where a save from a stale tab or editor silently overwrote newer store-backed artifact content. The root cause is solved: PATCH /api/artifacts/{slug} now takes an optional expected_token, and ArtifactStore.update() compares it under the store lock, using hmac.compare_digest, against a random 256-bit content_token kept in meta.json. A mismatch raises ArtifactConflictError, which the handler turns into a 409 that names current_token. I read the full production diff. The token is rotated before current.html is rewritten, so a partial write can cause a false 409 but never admit a stale save. File-backed live pointers and versioned reads carry no token. The token is only serialized beside current content. Callers that send no token (MCP, revert) keep last-write-wins, so nothing regresses. On the page, only the explicit relabelled Save button sends the overwrite token, saves that are already in flight are skipped, and an edit-generation guard stops a late completion from touching another editor's state. The new 409/400/token tests in test/test_artifacts.py, test/test_artifacts_handlers.py and ArtifactDetailPage.saveConflict.test.tsx would fail on base. All checks are green on head df55b83, GPT/Design/First Principles show PASS or no findings, and every UX CONCERNS item on this head has an evidence-backed disposition. One non-blocking nit from the Opus lane (ArtifactDetailPage.tsx:~2003): the version selector leaves edit mode without calling setSaveConflict(false), so a later unrelated error can show under the conflict title. A one-line follow-up can fix it. — crew-pr-reviewer

@KiroCrewCaptain
KiroCrewCaptain merged commit 2f5261c into kirodotdev:main Oct 8, 2026
104 checks passed
@github-actions github-actions Bot removed the readiness: passed Eligible automated validation passed for the current revision label Oct 8, 2026
@peterhieuvu

Copy link
Copy Markdown
Contributor Author
  • fixed span=6504b7c8bc2e Version switch leaves saveConflict set after a 409

Fixed in follow-up #18229 (commit 090cb79), which closes #18182. Cancel, Escape and the Version selector now end an edit through one step that clears the save error, the conflict flag and the preview toggle.
That step also advances the edit generation, so a save or pull flush refused after the user left the edit no longer re-arms the notice.
New tests in ArtifactDetailPage.saveConflict.test.tsx cover the version switch, a late pull-flush refusal, a late save refusal and the preview toggle. Each fails on this head's page.

@mbriones98 mbriones98 removed the drive-to-green PR claimed by drive-to-green pipeline label Oct 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fork Pull request from a fork (external contributor)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Artifact PATCH has no stale-write protection — concurrent editors silently clobber each other's content

6 participants