Skip to content

fix: a stamp the notary reports written is a stamp that reads back — and 3.3.0 - #209

Merged
TinDang97 merged 3 commits into
mainfrom
fix/stamp-field-integrity
Sep 1, 2026
Merged

fix: a stamp the notary reports written is a stamp that reads back — and 3.3.0#209
TinDang97 merged 3 commits into
mainfrom
fix/stamp-field-integrity

Conversation

@TinDang97

Copy link
Copy Markdown
Collaborator

One defect fix, then the 3.3.0 version bump.

The fix — a stamp the notary reports written is a stamp that reads back

_oneline exists because an unbalanced { in a --reason once made the parser swallow the following stamp — two records written, one read back, from an append-only ledger whose ordering is the trust model. That fix was correct and was applied to exactly one field. Seven writers interpolated by: raw.

$ add freeze t --by 'O"Brien' --authority human
freeze recorded at authority `human`     # reported as SUCCESS

stamp keys read back: ['by']             # act, authority, direction swallowed
_is_frozen       -> False
sealed_direction -> None

The seal silently does not exist while the human is told it does. The trigger is an odd number of " — a balanced pair (Tin "TinDang97" Dang) round-trips, which is exactly why this survived every real use of the engine.

Severity, stated plainly: it fails CLOSED. The gate then refuses with R:UNSEALED, so nothing is let through. The defect is that a notary whose only job is to record faithfully reported a record it did not write → R:LIE.

All seven interpolations (freeze · brief · replan · check · interview · both gate paths) now go through _oneline, and the reason is written at the function's own definition, since the fix is one careless edit away from reverting. test_every_stamp_writer_normalises_its_by enumerates the writers from the source, never from a hand list — a hand list is precisely how the seventh writer got missed, which is the shape of the defect itself.

The gate refused the first PASS: M4 ("a verb reports a refusal, never a false success") was declared with no check. Rather than staple a covers: onto an existing one, the punctuation walk now asserts the biconditional — what the verb reports must match what the ledger holds. A success that wrote an unreadable record and a refusal that wrote a good one are both the notary lying.

Corrections to my own earlier report, disclosed rather than quietly fixed

  • I first reported this as a brace bug that destroyed the entire verified: ledger. That was wrong. The probe behind it froze an unauthored node, so freeze correctly refused on template placeholders and wrote nothing — I read a correct refusal as corruption. Corrected on feat: RISK-ACCEPTED signs for weak evidence never a missing seal, and the ONE approval asks its questions out loud #208 as well.
  • M1 (_oneline neutralises the quote) was already true before this task; _oneline has always replaced ". It stays as a regression pin, but the real rule is M2 — the writers that never called it.
  • test_no_existing_stamp_is_rewritten first compared whole-file text, which a later write legitimately grows. It compares the parsed stamp list now.

The release — 3.3.0

Six version sources in lockstep: pyproject.toml · package.json · package-lock.json (2 places) · .claude-plugin/plugin.json · src/add_method/__init__.py · tooling/add.py's ENGINE.

Bumping ENGINE re-aims add.py, so the four engine twins are resynced, ENGINE_MD5 re-aimed, and both dogfood bundles' engine:/tooling_engine: stamps moved — those ride every version bump and go stale silently otherwise.

The CHANGELOG covers what #207, #208 and this PR shipped: the scaffold beat · the claimed-output guard · the INTEGRITY/EVIDENCE split · done's seal check · the template-Milestone refusal · segment-aware _paths_touch · sensitivity flooring up · add interview · this stamp fix. It says the RISK-ACCEPTED hole failed closed and that the stamp defect made a verb report a record it had not written, because a changelog that only lists wins is the same failure mode as a guard that only checks the happy path.

873 passed / 0 failed / 7 skipped across both roots.

Not in this PR

Tag and publish remain the human call. Pushing v3.3.0 triggers the npm + PyPI publish, and neither registry lets a version be reused. Nothing here pushes a tag.

… back

`_oneline` exists because an unbalanced `{` in a `--reason` once made the parser
swallow the following stamp. That fix was correct and was applied to exactly one
field. Seven writers interpolated `by:` raw.

Measured on the incumbent engine:

    $ add freeze t --by 'O"Brien' --authority human
    freeze recorded at authority `human`     # reported as SUCCESS
    stamp keys read back: ['by']             # act, authority, direction swallowed
    _is_frozen -> False  ·  sealed_direction -> None

The seal silently does not exist while the human is told it does. The trigger is
an ODD number of `"`; a balanced pair round-trips, which is exactly why this
survived every real use of the engine.

Severity, stated honestly: it fails CLOSED. The gate then refuses with
R:UNSEALED, so nothing is let through. The defect is that a notary whose only
job is to record faithfully reported a record it did not write -> R:LIE.

All seven `by:` interpolations now go through `_oneline` (freeze · brief ·
replan · check · interview · both gate paths), and the reason is written at the
function's definition, since the fix is one careless edit away from reverting.

`test_every_stamp_writer_normalises_its_by` enumerates the writers FROM THE
SOURCE rather than from a hand list — a hand list is precisely how the seventh
writer gets missed, which is the shape of the defect itself.

Corrections to my own work, both disclosed rather than quietly fixed:

  * I first reported this as a BRACE bug that destroyed the whole `verified:`
    ledger. That was wrong. The probe behind it froze an UNAUTHORED node, so
    `freeze` correctly refused on template placeholders and wrote nothing — I
    read a correct refusal as corruption. The claim is corrected on PR #208.
  * M1 (`_oneline` neutralises the quote) was already TRUE before this task;
    `_oneline` has always replaced `"`. It stays as a regression pin, but the
    real rule here is M2 — the writers that never called it.
  * `test_no_existing_stamp_is_rewritten` first compared whole-file text, which
    a later write legitimately grows. It compares the parsed stamp list now.

873 passed across both roots. Twins synced, ENGINE_MD5 re-aimed.

author: Tin Dang
The gate refused the first PASS: M4 was declared with no check. The punctuation
walk proves the property, so it now asserts the BICONDITIONAL — what the verb
reports must match what the ledger holds — rather than gaining a stapled covers.

Gated PASS at `plan` on receipt 2, 11/11 bound.

author: Tin Dang
Six version sources in lockstep: pyproject.toml · package.json ·
package-lock.json (2 places) · .claude-plugin/plugin.json ·
src/add_method/__init__.py · tooling/add.py's ENGINE.

Bumping ENGINE re-aims add.py, so the four engine twins are resynced, ENGINE_MD5
re-aimed, and both dogfood bundles' `engine:`/`tooling_engine:` stamps moved to
add/3.3.0 — those ride every version bump and go stale silently otherwise.

CHANGELOG covers the release honestly, including that the RISK-ACCEPTED hole
failed CLOSED and that the stamp defect made a verb report a record it had not
written.

873 passed / 7 skipped across both roots.

Tag and publish are NOT part of this commit — they remain the human call.

author: Tin Dang
@TinDang97
TinDang97 merged commit 1e80dd3 into main Sep 1, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant