Repository navigation
test: Retarget Hermes marker tests onto the declared logical export - #5104
Conversation
PR #5040 (f84dd3b) added the is_declared_logical_export gate at archive/raw_payload/decode.py:587, so a SQLite page image is no longer admitted as session content. Three tests still built a page image and asserted the pre-#5040 marker route. Rebuild them on the production acquisition shape -- write_logical_export plus member_export_scope -- following the precedent PR #5064 (3ad255e) set for the equivalent storage tests. The assertions are unchanged in substance: the marker route still fires and the payload still equals hermes_state.marker_payload. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01DYUNBGoE652b3nfmq3CtqK
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Warning Review limit reachedNext included review available in 8 minutes. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (2)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Three tests still built a Hermes SQLite page image and asserted the
pre-#5040 marker route. They are retargeted onto the production acquisition
shape -- the declared member's canonical logical export -- which is what
the gate now admits.
Which merged PR moved the ground
PR #5040 (
f84dd3b0c, "Refuse Hermes page images on ingest") added theis_declared_logical_exportgate atarchive/raw_payload/decode.py:587. Apage image is no longer admitted as session content, because the replay route
(
sources.revision_backfill._parse_one) already refuses one and admitting iton ingest would mint a second source authority for content the archive holds
under its logical revision.
PR #5064 (
3ad255e25) already rewrote the equivalent storage tests ontowrite_logical_export+member_export_scope. These three were missed bythat pass; this follows the same precedent.
Solution
Build the retained material with
write_logical_export(db, handle, scope=member_export_scope(db), immutable=True)and pass the export as thepayload with
source_pathnaming the declaredstate.db. The assertions areunchanged in substance: the marker route still fires, the artifact is still a
SESSION_DOCUMENT, and the payload still equalshermes_state.marker_payload(...).tests/unit/sources/test_parsers_local_agent.pygrows one helper,_write_hermes_state_export, shared by both marker tests.Verification
The one failure in that receipt was
tests/unit/cli/test_status.py, aseparate group with its own PR; it is green there.
Anti-vacuity
..._still_recognizes_genuine_hermes_state_dbscope=None): the bytes stop binding tostate.db, the artifact comes backBINARY_DATABASE..._envelope_uses_markerProvider.HERMES..._default_keeps_live_marker_semanticssqlite_immutabledefault to True: the marker gains ansqlite_immutablekeyResiduals
Test-only change; no product code touched, so the derived schema identity does
not move. The full corpus was not re-run.
🤖 Generated with Claude Code
https://claude.ai/code/session_01DYUNBGoE652b3nfmq3CtqK