{{ message }}
fix(daemon): persist judgment scheduler receipts (#3896) - #3896
Merged
Merged
Conversation
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
Repair judgment scheduler receipts and their daemon, API, and CLI projections. The change keeps one authoritative receipt per committed operation, makes durable outbox recovery bounded and failure-atomic, and exposes fresh queue health through the production status routes.
Problem
The scheduler could lose operation identity during receipt coalescing, accept malformed durable receipt evidence, append a competing failure after an acknowledgement failure, use an ambient archive root instead of an explicit one, and report stale or incomplete queue health. Direct CLI fallback also omitted the configured interval.
Solution
No durable schema migration or production archive mutation is part of this change.
Verification
POLYLOGUE_PYTEST_WORKERS=1 PATH="$PWD/.venv/bin:$PATH" devtools test tests/unit/daemon/test_judgment_automation.py tests/unit/daemon/test_daemon_status.py tests/unit/cli/test_status.py tests/unit/api/test_assertion_candidate_queue_health.py -k 'not archive_facade_route_catalog_covers_public_async_facade': 230 passed.PATH="$PWD/.venv/bin:$PATH" devtools test tests/unit/daemon/test_judgment_automation.py -k 'operation_owned_receipts or receipt_context_rejects or semantically_invalid_counter or replays_receipt_markers': 4 passed.PATH="$PWD/.venv/bin:$PATH" devtools verify --quick: all 24 steps passed, including mypy, layering, policy, lint, and generated-surface checks.git diff --check origin/master...HEAD: passed.The unfiltered focused selection also exposed one inherited repository baseline failure in
tests/unit/cli/test_status.py::test_archive_facade_route_catalog_covers_public_async_facade: the currentorigin/masterfrom Ref #3902 has the public route without the catalog entry. That unrelated route catalog was not changed; the affected selection above excludes only that test.Whole-Bead disposition
polylogue-5bxpydevtools verify --quickin the structured carrier belowReview disposition
The six requested review dimensions and the exact-head recovery findings are covered by the commits and tests above. The final carrier binds this body to the rebased PR head. The PR remains non-draft and is not being merged by this change.