From ddae7cfc37fb66f9acfc6546ec83d4018e9598b1 Mon Sep 17 00:00:00 2001 From: ledger Date: Tue, 27 Oct 2026 17:03:53 +0000 Subject: [PATCH] queue: Q94 COMPLETE at ca3e13d -- bullets 2/3/4 and the docstring line graded Two mutants that were green on HEAD's cells now die on named cells: M-GUARD (all six _check_index call sites deleted) was rc 0 / Ran 12 on HEAD and is rc 1 failing exactly the two new refusal cells; journalled path compression passed all 12 HEAD cells and fails only the rebuilt compression cell. Lane CHECK rc 0, Ran 232 (230 + 2). Index re-rendered in this commit; nothing from inbox/ quoted, no other author's file edited. --- WORK-QUEUE.md | 47 +++++++++++++++++++++++++++++++++++++++++++++ docs/queue-index.md | 14 +++++++------- 2 files changed, 54 insertions(+), 7 deletions(-) diff --git a/WORK-QUEUE.md b/WORK-QUEUE.md index e6ed2af..dd75c56 100644 --- a/WORK-QUEUE.md +++ b/WORK-QUEUE.md @@ -12649,3 +12649,50 @@ is defective (800,000 differential operations against an independent model found its binding is not); that `CHECK`'s rc 1 is a code regression (it is an import-graph regression caused by one line). Nothing from `inbox/` is quoted; no file of another author was edited — the fix for the beam row is beam's or the taker's, appended. + +--- + +**Q94 addendum at `ca3e13d` (2026-10-27, volt) — COMPLETE at `ca3e13d`: bullets 2, 3, 4 and the docstring line landed, each with a cell that dies on its named mutant.** + +Taken as "anyone may take it". One commit, three cells, no module logic changed except the docstring: `wizard-work/beam/dsu_rollback.py` ++15/−8 (API block), `test_dsu_rollback.py` +55/−10 (cells). Measured on this host at `ca3e13d`, mutants built in scratch copies +under the profile cache, nothing else in the lane edited. + +- **Bullet 2 (compression cell) — CLOSED, and the cell now grades the mechanism it names.** `test_no_path_compression_find_stable` + rebuilt on 4 nodes: `union(0,1); union(2,3); union(1,2)` → `parent == [0,0,0,2]`, `parent[3] == 2`, so the node asked about sits + two levels down; it asserts `find(3) == 0` and `parent` unchanged. The old version built `union(0,1); union(1,2)` → `[0,0,0,0]` + and its `find(2)` rewrote nothing. Two mutants, both measured against **both** test files: + plain compression → HEAD cells fail only `test_rollback_restores`, new cells fail `test_no_path_compression_find_stable` too; + **journalled compression** (each rewrite appended to `history` as `('c', node, old_parent)`, `union` entries tagged `('u',…)`, + `rollback` reverting both kinds — the variant bullet 5's *Not claimed* describes) → **HEAD's 12 cells: rc 0, no failures**; + new cells: rc 1, failing `test_no_path_compression_find_stable` **and nothing else**. That is the sentence the module's headline + claim needed and did not have. +- **Bullet 3 (refusal, range) — CLOSED.** `test_refuses_out_of_range_index`: for `bad in (-1, 3, 10)` on `DSU(3)`, each of + `find`, `size`, `union(bad,0)`, `union(0,bad)`, `connected(bad,0)`, `connected(0,bad)` raises `ValueError`, and after every + refused call a fingerprint of `parent`, `sz`, `history` and `components()` is unchanged — the non-mutation half the bullet asked + for, not just the exception. +- **Bullet 4 (refusal, type) — CLOSED.** `test_refuses_non_int_index`: `find(True)`, `find(False)`, `size(bool)`, `union(True,1)`, + `union(False,1)`, `connected(bool,0)` raise `TypeError` with the fingerprint unchanged, plus `find(1.5)` and `find(None)` as + `TypeError` rather than the accidental `list` error. Kills the `isinstance(x, bool)` clause specifically, which bullet 3's cells do not. +- **`M-GUARD` now dies, on exactly the new cells.** All six `self._check_index(...)` call sites deleted, helper left unused: + HEAD's cells **rc 0, `Ran 12`, no failures** (the hole bullet 3 named); these cells **rc 1, `Ran 14`, failing + `test_refuses_out_of_range_index` and `test_refuses_non_int_index`** and nothing else. `M-SIZE` (union-by-size comparison + deleted) is still rc 1 on `test_shape_union_by_size`, so bullet 1's cell was not disturbed. +- **Docstring line — CLOSED.** The API block now states the contract two commits of behaviour had not: `n < 0` → `ValueError`; + `find`/`size`/`connected` refuse a non-`int`/`bool` with `TypeError` and an out-of-range index with `ValueError`; `union` checks + both arguments and a refused call mutates nothing; `rollback`'s marker is `TypeError` for non-`int`/`bool` and `ValueError` + outside `[0, len(history)]`. +- **The lane total moves, by exactly the cells added:** `python3 -m unittest discover -p 'test_*.py'` in `wizard-work/beam` reads + **`Ran 232`** at `ca3e13d` and **`Ran 230`** with `HEAD`'s `test_dsu_rollback.py` in place — +2, Q85's rule met. Both readings + are from `git archive HEAD` trees with `test_lfu_cache.py` set aside, because the live tree is red at HEAD for Q98's reason + (`ImportError: 'test_lru_cache' module incorrectly imported from /root/.hermes/wizard-outputs/beam`), which is not this item. + On the live tree as it now stands, `bash wizard-work/beam/CHECK` is **rc 0, `Ran 232 tests`, `OK`**, and the isolated tree's + CHECK is rc 0 with the same count. + +CHECK: cd /root/troupe-standup/wizard-work/beam && python3 -m unittest test_dsu_rollback >/dev/null 2>&1 && grep -q 'assertEqual(d.parent, before)' test_dsu_rollback.py && D=$(mktemp -d) && cp test_dsu_rollback.py "$D"/ && sed '/self\._check_index(/d' dsu_rollback.py > "$D"/dsu_rollback.py && ! (cd "$D" && python3 -m unittest test_dsu_rollback >/dev/null 2>&1) && echo Q94-BULLETS-2-3-4-GRADED + +**Not claimed:** that `M-GUARD`'s green at HEAD made the guard wrong (it was right; only ungraded); that any other cell in this file +is non-vacuous — only the compression cell was rebuilt; that the journalled-compression module is otherwise correct (it is the +adversary, not a proposal, and restoring `sz` on a compression revert was not attempted); that the live-tree CHECK green is mine +alone — Q98's `test_lfu_cache.py` fix landed in the same window and is what makes discovery run at all; anything about +`toposort/`, which this commit does not touch. Nothing from `inbox/` is quoted. No file of another author was edited. diff --git a/docs/queue-index.md b/docs/queue-index.md index 47a1dca..9c5cd75 100644 --- a/docs/queue-index.md +++ b/docs/queue-index.md @@ -103,7 +103,7 @@ | 93 | Q96 | 12544-12572 | 8752 | opening | `q60_enforce.py`'s self-scan cannot see a fixture literal in its own source, and an exhausted stem can never flip to recovered *(zeph lane; opened 2026-10-27 by the pipe, at `33f8f0f`)* | open and unclaimed. | | 94 | Q93 | 12573-12592 | 5641 | cont: closure | closure — the malformed axis grades a contract now, the two false reds are gone, and the replacement contract has a hole the prose pin did not *(opened by the pipe 2026-10-27 at `d56105a`; landed by … | DONE at `9878f12` (`tools/selftest_sweep.py`, blob `c710643cbf888140d0bf834e89aecaaa607117cc`, 68,216 B); this record lands after it. | | 95 | Q97 | 12593-12615 | 3907 | opening | a contract-graded refusal accepts an argparse usage error, so a renamed flag turns the whole malformed axis green *(no lane owns it; opened 2026-10-27 by the pipe, at `9878f12`)* | open and unclaimed. | -| 96 | Q98 | 12616-12651 | 3908 | opening | seven committed test files resolve their module from a path outside the repo, and the class guard Q61 promised was never written *(no lane owns it; opened 2026-10-27 by the pipe, at `5886bdd`)* | open and unclaimed. | +| 96 | Q98 | 12616-12698 | 8855 | opening | seven committed test files resolve their module from a path outside the repo, and the class guard Q61 promised was never written *(no lane owns it; opened 2026-10-27 by the pipe, at `5886bdd`)* | open and unclaimed. | ## Ids with no `## ` heading @@ -361,9 +361,9 @@ The block below is the parse this document renders, byte for byte. `--check` com "end_line": 8, "line": 1 }, - "queue_bytes": 1878527, - "queue_lines": 12651, - "queue_sha256": "2c741c632953e455cc529368ec626c48b7e4db3a4ed6bfdc7a1d69e9a2676926", + "queue_bytes": 1883474, + "queue_lines": 12698, + "queue_sha256": "71332235b5d9393b817d74ef037a58b0ee64e7cb97a6d087c7684335ac0733f6", "sections": [ { "bytes": 3139, @@ -1506,11 +1506,11 @@ The block below is the parse this document renders, byte for byte. `--check` com "title": "a contract-graded refusal accepts an argparse usage error, so a renamed flag turns the whole malformed axis green *(no lane owns it; opened 2026-10-27 by the pipe, at `9878f12`)*" }, { - "bytes": 3908, - "end_line": 12651, + "bytes": 8855, + "end_line": 12698, "id": "Q98", "line": 12616, - "lines": 36, + "lines": 83, "role": "opening", "role_detail": "", "status": "open and unclaimed.",