test: retire mechanical known-red ledger rows (uxrim, bwo2l/vqt48, ndgbm-quiet, 7qw4) - #4006
Merged
Merged
Conversation
polylogue-ndgbm's quiet component: QueryCardinalitySession.wire_records() emitted only function_call/function_call_output response_items, so codex.is_supported_session_stream() (has_message never set) refused every payload before ingest and the module-fixture errored at setup. Add a planted user/assistant message pair per session (mirrors the "message" response_item shape landed for polylogue-bwo2l/6mpy) so the stream is admitted; action-identity assertions are unaffected since they only count tool rows. Removing the two xfail markers this unblocks surfaced two further issues once the tests could actually run to completion, both fixed in the same commit: the naive-duplicate-join mutation test's hand-rolled `actions` view predates the production view's `result_state` CASE projection (polylogue-cuxz.5) and crashed with `no such column` instead of producing the comparable-but-wrong row count the test asserts on; and the real `--yes --all` delete-apply route has no non-daemon path, so the survivor now stands in for the daemon's three-step delete the same way test_verb_cardinality.py's TestDeleteCardinalityLargeNonMocked already does. `_copy_archive` also re-binds the durable bootstrap marker after cloning (mirrors tests/infra/workload_artifacts.py's clone_seeded_archive), since a naive copytree leaves a marker whose durable_identity_digest is bound to the original path and the first write-mode open at the new path was rejected as a durable identity mismatch. Ref polylogue-ndgbm Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01HWcPJJJvuF25CqVwTFgSQC
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: 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 |
Sinity
added a commit
that referenced
this pull request
Aug 19, 2026
## Summary `cleanup_managed_tmpfs_path` now removes read-only artifact trees: plain rmtree first, then a chmod-owner-write walk + retry if anything survived. ## Problem Seeded-archive artifacts chmod their directories non-writable. When a test builds a cache under the tmpfs basetemp (`query_cardinality_archive` does), `shutil.rmtree(ignore_errors=True)` silently leaves the tree behind, the supervisor reports `tmpfs_cleanup_complete: false`, and `devtools verify` withholds `release_baseline_allowed` on an otherwise-green receipt. This blocked the #4006 merge twice on 2026-08-19 (runs 20260819T003921Z, 20260819T010648Z; 16 leaked /dev/shm dirs confirmed) and became SYSTEMATIC once #4006 unblocked the query-cardinality fixture — every full-mode receipt now builds the read-only cache. Ref polylogue-b9yw7 (root cause recorded there); the eager stale-dir sweep half of the operator's never-leak mandate stays with the A4 harness lane. ## Solution Two-pass removal in `cleanup_managed_tmpfs_path` (ownership checks unchanged): rmtree, then `_restore_owner_write` (chmod u+w over root+rglob) and rmtree again only if residue survived. No behavior change for the already-clean path. ## Verification `devtools test tests/unit/devtools/test_pytest_supervisor.py -k cleanup` → 2 passed. Red twin demonstrated: with the fix stashed, the new `test_cleanup_managed_tmpfs_path_removes_read_only_artifact_trees` fails (read-only subtree survives); with the fix, removed. `devtools verify --quick` → success (mypy clean after replacing the onexc handler with the two-pass shape — the pinned stubs reject `onexc`). ## Bead disposition Self-contained; Ref polylogue-b9yw7 (narrows it; closure judgment stays with the A4 lane's fuller investigation). <!-- polylogue-pr-scope:v2 { "assigned_beads": [], "dispositions": [], "mutated_beads": [], "scope_digest": "79a7984a9ec80a157c96dc8d28561159c642c15de3793837eff751fa7eac34a1", "scope_kind": "self_contained", "version": 2 } --> Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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
Retires the four mechanical rows of the WS-B known-red/false-green ledger
(
.agent/campaigns/2026-08-overhaul/ws-b-suite-health.md): uxrim, bwo2l,vqt48, and 7qw4 were all already satisfied on master before this branch was
cut; the one row that needed real work was polylogue-ndgbm's quiet
component (Codex query-cardinality oracle's fixture never emitted a
message-shaped record, so the parser's admission gate refused everypayload and the module fixture errored at setup), which this PR fixes and
whose two associated xfail markers it removes.
Problem
The ledger recorded five findings as known-red or false-green test debt,
each with a RECIPE and file:line anchors, dispatched here as a themed sweep.
Solution
uxrim (
tests/unit/api/test_facade_contracts.py:4789): the recipeasked to extend the
frozen_clock_modulesmarker to also coverrevision_governance. Already done — commit 8ed4f91 (PR fix(tests): repair storage-cluster test drift from origin-vocab+clock-guard fixes #3595,2026-08-03) landed exactly that extension. No diff needed.
7qw4 (
tests/unit/storage/test_store_ops.py): the recipe asked torewrite the test to call the production
aggregate_message_statsasyncfn and delete a test-local shadow reimplementation. Already done —
commits from PR test(storage): exercise aggregate message stats repository path #3729 (call the repository path) and PR test(storage): assert aggregate stats use public origins #3813 (assert on
public
origins) landed this; no shadow function remains in the file. Nodiff needed.
bwo2l + vqt48 (
tests/unit/cli/test_archive_maintenance_cli.py,tests/unit/sources/test_live_watcher.py,tests/unit/sources/test_live_batch_support.py): the recipe asked to giverefused codex fixtures real conversational content. Already done — the
9ykn positive-evidence-gate fixes landed across several prior PRs (visible
in
git log --grep: fix(test): add real message content to raw-materialization fixtures #3555, test(storage): give raw-authority-ledger codex fixtures real message text #3572, fix(sources): require a genuine chunk in gemini/drive chunkedPrompt detection #3600, fix(devtools): give synthetic codex raw payloads real message text #3642, test(sources): verify origin parser claims #3841). All 138 + 259tests pass.
ndgbm quiet component (
tests/infra/query_manifest_oracle.py,tests/unit/cli/test_query_composition_laws.py): the actual fix in thisPR.
QueryCardinalitySession.wire_records()emitted onlyfunction_call/function_call_outputresponse_items — zeromessage-shaped records — socodex.is_supported_session_stream()(
has_messagenever set) refused every payload before ingest and themodule-scoped fixture errored at setup before either test could run.
Added one planted user/assistant message-pair response_item per session
(same wire shape landed for the bwo2l/vqt48 fixtures), which admits the
stream; action-identity assertions are unaffected because they only count
tool rows.
Removing the two xfail markers this unblocks surfaced two further
pre-existing issues that had never been reachable before (the tests always
errored at setup), fixed in the same commit:
actionsviewpredates the production view's
result_stateCASE projection(polylogue-cuxz.5,
archive_tiers/index.py:1040) and crashed withsqlite3.OperationalError: no such column: a.result_stateinstead ofproducing the comparably-wrong row count the test actually asserts on.
Added the same CASE projection to the test's naive view.
find ... then delete --yes --allhas no non-daemon route — it refusesoutright when the daemon does not answer the
/preparecall. Added adaemon-delete stand-in patch on
_submit_daemon_mutation, mirroring theexisting pattern in
test_verb_cardinality.py::TestDeleteCardinalityLargeNonMocked._daemon_delete_route(does the real delete through
ArchiveStore, just skips the daemonprocess).
_copy_archive's plainshutil.copytreeleft the durable bootstrapmarker bound to the original archive root path
(
durable_identity_digest), so the first write-modeArchiveStore.open_existingat the copied path raised
DurableChangeTrainError: fresh durable bootstrap marker durable identity mismatch. Re-bind the marker aftercopy, mirroring
tests/infra/workload_artifacts.py::clone_seeded_archive.ndgbm residual (not closed by this PR): the bead also names a second,
separate symptom — the 64-seed process-pool death only reproduces beside a
saturated 10-worker gate (confirmed load-only: quiet re-run 20260818T231534Z
was green in 43s). That's a load-robustness question the dispatch prompt
asked to coordinate with WS-A's e98k cgroup-mmap-budget findings. I could not
type this as a
partialdisposition in the machine-readable pr-scopecarrier below: the validator requires a pre-existing Beads dependency
edge (
blocks/discovered-from/relates-to/supersedes) between ndgbmand its named successor before it will accept the disposition, and no such
edge exists between polylogue-ndgbm and polylogue-e98k today. Per the lane
contract I do not invoke
bdfrom a worktree, so I did not create thatlink. Coordinator action needed: link
polylogue-ndgbm→polylogue-e98k(or a dedicated new successor) viabd dep add(orequivalent) before ndgbm can be typed
partialin a carrier; until then thebead should stay open with its residual noted in its own notes (already
present).
Verification
devtools test tests/unit/api/test_facade_contracts.py -k raw_artifacts_read_source_tier→ 1 passed (uxrim, unchanged/confirmed)devtools test tests/unit/cli/test_archive_maintenance_cli.py→ 138 passed (bwo2l, unchanged/confirmed)devtools test tests/unit/sources/test_live_watcher.py tests/unit/sources/test_live_batch_support.py→ 259 passed (vqt48, unchanged/confirmed)devtools test tests/unit/storage/test_store_ops.py -k aggregate_message_stats→ 1 passed (7qw4, unchanged/confirmed); mutation red-check locally re-applied AG1 (role-swap on the unfilteredrole_rowquery) and AG2 (words_approx = 0) againstpolylogue/storage/sqlite/queries/stats.py, both now fail (assert 1 == 2,assert 0 == 9), reverted before commit — no diff shipped for this rowdevtools test tests/unit/cli/test_query_composition_laws.py→ 2 passed, 0 xfail (ndgbm quiet component: red→green; both-p no:testmonand cached runs confirmed)devtools verify --quick→ exit 0 (format + lint + mypy +render all --check; noout of syncin output)All four rows were verified in the context that was failing: each command
above is the exact standalone-context command named in the dispatch recipe,
run directly (not nested inside a broader suite run).
Bead disposition matrix
partial)Ref polylogue-uxrim, polylogue-bwo2l, polylogue-vqt48, polylogue-ndgbm, polylogue-7qw4
🤖 Generated with Claude Code
https://claude.ai/code/session_01HWcPJJJvuF25CqVwTFgSQC