Repository navigation
An effort, place or working copy recorded right after a message is no longer overwritten by its stamp - #2557
Merged
Merged
Conversation
…t writes The dev port of the app/v3 fix for #2549. stampUserLocked captures the model, effort, approval, places and trees when a person speaks and writes them behind the path. stampMeta, which effort, places and trees use, wrote synchronously without waiting for that deferred write. So an effort, a place or a working copy recorded while the stamp was still owed was overwritten with the older values when the stamp landed, and the next process read them back as they were before. This has been true since the deferred user stamp arrived on 2026-09-11 (#876), including v0.8.2. stampModel got this guard on 2026-10-07 (#1750); stampMeta did not. stampMeta now settles the owed metaStamp before it takes its snapshot. TestAnEffortSetWhileTheOpeningStampIsOwedIsTheOneKept holds the stamp until the effort's write is waiting on it. It fails 10 of 10 without the settle and passes 50 of 50 with it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
devport of #2556 (theapp/v3fix for #2549).devhas the same deferred stamp and the same unguardedstampMeta, so the terminal product that ships from here had the bug too.What was true
stampUserLockedcaptures the model, effort, approval, places and trees when a person speaks. It writes them behind the path, as a deferredmetaStampwrite.stampMeta, whichstampEffort,stampPlacesandstampTreesuse, wrotemeta.jsonsynchronously and did not wait for that write.So an effort, a place or a working copy recorded while the stamp was still owed got overwritten with the older values when the stamp landed. The next process then read them back as they had been before. The working copy is the serious one, because it holds work that exists nowhere else.
stampModelgot this guard on 2026-10-07 (Refine Teams overviews, shared conversations and scoped deletion #1750);stampMetadid not.What is true now
stampMetasettles the owedmetaStampbefore it takes its snapshot, so whatever lands second is the newer state. When nothing is owed, the settle returns at once.Proof
New test
TestAnEffortSetWhileTheOpeningStampIsOwedIsTheOneKept. It holds the opening stamp through a nil-in-production seam until the effort's write is waiting on it. There is no clock in it.meta.json says "" after the opening stamp landed.TestAppEffortRungsRoundTripRealEngineand its focused-retry fix exist only onapp/v3, so they are in #2556, not here.🤖 Generated with Claude Code