Rust RUDP server: pin blank schemaId/recordKey refusal, decide sequenced refusal per frame #63
Loading…
Reference in a new issue
No description provided.
Delete branch "libby/rs-receipt-key-tests-per-frame"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Two Rust-only follow-ups on the RUDP document server (packages/cultmesh-rs), both from Heimdall's round-three review.
heimdall-low-rust-keys-untested: testa_write_whose_schema_id_or_record_key_names_nothing_is_refused_and_never_handed_to_the_store. For put and delete, withschemaIdorrecordKeyempty, a space, or"\t \n": refusedmessage_invalid,details.field"message", the write's id; the store'sauthorize_raw_documentis never called for it, nothing applied, session goes on (spec rule 5; vectorerror_v1_empty_schema_id_is_unreadable_and_names_the_write).heimdall-low-refuse-sequenced-per-frame:deliveredwas not only this packet's frames; a reliable-sequenced packet filling the gap an ordered packet was held behind released that ordered write in the same delivery, and it was refused too. The refusal now applies to a frame only whenframe.sequence <= packet.sequence(the packet's own frame; released ordered frames sit above it). Testa_sequenced_packet_releasing_a_held_ordered_write_refuses_only_its_ownfails before the fix (2 refusals, expected 1).Regions touched in
src/rudp_document_server.rs: only theif refuse_sequencedcondition in theresult.deliveredloop ofpoll_once(+ 2 comment lines). The text/blank-field code (missing_required_write_fielduse, rejection reasons) is untouched. Tests are appended beforea_refused_write_keeps_the_session_from_going_idle, plus one helperswap_fixstr.Mutation (cargo-mutants 27.1.0,
prlimit --as=4GiB --cpu=300,-j1):cargo mutants --listgenerates forrequire_non_emptyonly the body-to-Ok(())mutant (it does not generate a trim-dropping one), and it cannot run the cultmesh test against a mutation in the separate cultnet-rs crate, so I applied by hand: body toOk(())caught;value.trim().is_empty()tovalue.is_empty()caught;validate_raw_document_recordtoOk(())caught.--in-diffover the src change: 3 mutants, 2 caught (&&->||,<=->>), 1 unviable (poll_once->Ok(Default::default())), 0 missed. The pre-fix behaviour (no per-frame condition) is the test's failing baseline.🤖 Generated with Claude Code
Merged head and what is not in main
This PR merged at head
2f3b30ab. The two follow-ups above (key-refusal test; refuse-sequenced-per-frame condition) are what main holds.An earlier version of this description carried an "Update
74705c7c" section (serial-arithmetic frame/packet ordering and refusing a superseded sequenced write from its own payload). That commit was never pushed to the forge and is not in main, so those changes and thewrite-receipt.mdsentence about unanswered superseded fragments are not merged; they remain a follow-up.f6b27a86f3636b387cf1