jcp-receipt: move an orphaned doc comment onto the test it describes #209

Merged
dcharlot merged 1 commit from dcharlot/jcp-receipt-orphan-doc into main 2026-10-13 02:40:07 -04:00 AGit
Owner

Revives #98 (opened 2026-09-19, 1063 commits behind main) by cherry-picking its one commit onto current main. Re-verified against main first: legacy_jcp1.json exists and carries both an allow and a deny, and jcp-conformance/tests/pack.rs reads it, so the corrected text is accurate. jcp-receipt 21 tests pass. Supersedes #98, which I will close.

Revives #98 (opened 2026-09-19, 1063 commits behind main) by cherry-picking its one commit onto current main. Re-verified against main first: legacy_jcp1.json exists and carries both an allow and a deny, and jcp-conformance/tests/pack.rs reads it, so the corrected text is accurate. jcp-receipt 21 tests pass. Supersedes #98, which I will close.
jcp-receipt: move an orphaned doc comment onto the test it describes
All checks were successful
standards workspaces build + test / jouleclaw-rs (pull_request) Successful in 6m49s
standards workspaces build + test / aac-rs (pull_request) Successful in 3m40s
standards workspaces build + test / joule-code-rs (pull_request) Successful in 1m37s
standards workspaces build + test / joulecontract-rs (pull_request) Successful in 1m9s
standards workspaces build + test / map-rs (pull_request) Successful in 1m10s
standards workspaces build + test / mesh-rs (pull_request) Successful in 1m10s
standards workspaces build + test / openpay (pull_request) Successful in 7m28s
standards workspaces build + test / arl-rs (pull_request) Successful in 1m9s
standards workspaces build + test / eoc-rs (pull_request) Successful in 1m58s
standards workspaces build + test / jcp-rs (pull_request) Successful in 1m31s
standards workspaces build + test / joule-ui-rs (pull_request) Successful in 1m10s
standards workspaces build + test / joulehook-rs (pull_request) Successful in 1m11s
standards workspaces build + test / proof-rs (pull_request) Successful in 1m14s
standards workspaces build + test / jouledesk-rs (pull_request) Successful in 6m27s
standards workspaces build + test / sandbox-rs (pull_request) Successful in 2m15s
standards workspaces build + test / sense-rs (pull_request) Successful in 1m6s
standards workspaces build + test / smart-byte-rs (pull_request) Successful in 3m53s
standards workspaces build + test / macOS energy backends (pull_request) Successful in 8m31s
b1686e1fc5
A paragraph headed "**The migration guarantee**" sits between two tests in
`jcp-receipt/src/lib.rs` with no item of its own. Rust therefore merges it into
the doc of the *next* item, `an_absent_environment_leaves_the_bytes_untouched` —
a test about environment bindings, which has nothing to do with legacy
receipts. It reads as documentation for a deleted test, and that is exactly how
I first read it.

It also names the wrong file. It says the bytes are "published in
`conformance/v1/vectors.json`"; they are in `conformance/v1/legacy_jcp1.json`,
and are byte-identical to the hex constant in `published_v1_receipts_still_verify`
(checked).

The paragraph now documents `published_v1_receipts_still_verify`, which is the
test that actually carries the guarantee, names `legacy_jcp1.json`, and notes
that the inlined constant is a copy of the file's **allow** envelope while the
file also carries a **deny** — both of which `jcp-conformance`'s
`tests/pack.rs` verifies against the file itself, via `extract` and so
`verify_cose_sign1`, requiring both verdicts to be present.

Doc comments only; `jcp-receipt` green.

This PR originally also added a `jcp-conformance/tests/pack.rs` reading the five
pack files nothing read. Main closed that independently in 1b3e3907, reading the
same files and reaching the same legacy-deny finding, so that half is dropped
rather than merged alongside. This correction is the part main did not make.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
Transaction-Science/open-standards!209
No description provided.