Under the hoodTier: how much it should matter to you
3Useful: my rating, 1 to 5
2Signal: worth watching, 1 to 5
File WritesArea: what it touches
Internal ChangesKind: in v2.1.275,
Internal ChangesSection of the release
What
The internal helper Claude Code uses to write files and other artifacts safely (writing to a temporary location and then swapping it in, so a crash never leaves a half-written file) now supports a beforePublish check that runs just before the write completes. If that check returns false, the write is aborted, a new PublishRefusedError is thrown, and nothing is published, including cleaning up any empty placeholder file that may have been created along the way.
Why
This gives internal callers a way to cancel a write at the last moment based on some condition, without risking a partially-written or stray file being left behind.