Skip to content

fix(standard): write the last six records through the shared writer - #370

Merged
harenome merged 1 commit into
ThinkFlowLab:mainfrom
harenome:fix/shared-writer
Nov 25, 2026
Merged

harenome merged 1 commit into
ThinkFlowLab:mainfrom
harenome:fix/shared-writer

Conversation

@harenome

@harenome harenome commented Nov 23, 2026 •

Copy link
Copy Markdown
Collaborator

Closes #366

What

  • Six records were written outside ondisk.write_whole. Three used a fixed temporary name: two writers shared it, and a leftover at that name stopped the write. Two were written in place: a reader could find a half-written config.json or result.json.
  • All six now use ondisk.write_whole:
    • the decision models cache;
    • a Boat job's merged config.json;
    • the version scaffold, inside the lock it already held;
    • a standard job's config.json and result.json;
    • a saved builder recipe, mode 0600.
  • Content and modes are unchanged.

Verified

  • On main (f23c69f) the new tests fail: a folder at the old temporary name stops the cache, the scaffold and the Boat config; a failed write leaves config.json and result.json half-written.
  • The job files hash the same on main and here.
  • Backend 3049, routes 578.

Risk

  • A job's config.json and result.json are new files on each write: a reader holding the old one keeps reading it.
  • A failed write leaves the previous file, not a truncated one.
  • Undo: revert.

Agents

  • Claude Code, Opus 5.5: code, tests

The decision models cache, a Boat job's merged config.json and the version
scaffold no longer write under a fixed temporary name; a standard job's
config.json and result.json are no longer written in place, so a reader
never finds them half-written; a saved recipe drops its own copy of the
writer and keeps mode 0600. Content and modes are unchanged.
@github-actions github-actions Bot added the merge conflict Conflicts with its base: merge or rebase it label Nov 25, 2026
@harenome harenome removed the merge conflict Conflicts with its base: merge or rebase it label Nov 25, 2026
@github-actions github-actions Bot added the needs review Tests pass, no conflict, no verdict on its latest commit label Nov 25, 2026
@harenome
harenome merged commit 6be66af into ThinkFlowLab:main Nov 25, 2026
3 of 4 checks passed
@harenome
harenome deleted the fix/shared-writer branch November 25, 2026 13:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs review Tests pass, no conflict, no verdict on its latest commit

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Six records are still written outside the shared writer, three under a fixed temporary name

1 participant