From 67ded86ef42f2cac23b2f55549bcac70f6b09159 Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:13:49 +0100 Subject: [PATCH 01/13] Make stability-reviewer check that keys built from path segments, or matched by prefix, cannot collide --- agents/stability-reviewer.md | 1 + docs/reading-cost.md | 151 +++++++++++++++++++++++++++++++++++ 2 files changed, 152 insertions(+) diff --git a/agents/stability-reviewer.md b/agents/stability-reviewer.md index 9738200c..6c377ab4 100644 --- a/agents/stability-reviewer.md +++ b/agents/stability-reviewer.md @@ -73,6 +73,7 @@ Catch behavior that is unclear or under-specified — "building in ambiguousness - Zero and absent are different values: `empty('0')`, `if ($amount)`, `$x ?: $default`, JS `||` conflate them one way; null coerced to `'0'` conflates them the other (a past prod bug: phantom 0-amount reversals). Both directions are findings. - Multibyte text (åäö): truncation, length checks, and comparisons must be mb-safe; encoding consistent end-to-end. - Where the change splits text on a separator or strips a suffix, look in the fixtures and a sample of the source data for a value where the separator or suffix also occurs as data, such as an address split on `,` whose last part holds a comma. Report a row the parse then misplaces or drops, silently or with only a log line. +- Where the change builds a lookup key by joining path segments, or matches a key by prefix, look for two inputs that give one key, such as a segment equal to its parent's name or a namespace that is a dot-prefix of another (`ns` and `ns.sub`). Report the input the lookup credits to the wrong entry. - Are payload and collection sizes bounded at the boundary? ### 6. Concurrency & State Management diff --git a/docs/reading-cost.md b/docs/reading-cost.md index 52080d6a..d9516e2c 100644 --- a/docs/reading-cost.md +++ b/docs/reading-cost.md @@ -3367,3 +3367,154 @@ Read most (opens and searches): - `bin/mutate-changes` 2 - `bin/mutate_changes/main.py` 2 - `bin/mutate_changes/test_mutate_changes_runs.py` 2 + +## Reading cost, chunk d56c1f21bd44, finished 2026-11-21T12:07:42Z + +136856 new input tokens before the first commit. + +Read most (opens and searches): + +- `bin/task_bench/main.py` 8 +- `bin/task_bench/test_task_bench.py` 6 +- `.gitignore` 3 +- `README.md` 3 +- `bin/claude_code/entries.py` 3 +- `bin/chunk_driver/project/model_choice.py` 2 +- `bin/git_cli/git_repo.py` 2 +- `bin/reading_cost/measure.py` 2 +- `bin/review_rules/review_folder.py` 2 +- `bin/task_bench/figures.py` 2 + +## Reading cost, chunk 666aabdd77a8, finished 2026-11-22T15:50:09Z + +283046 new input tokens before the first commit. + +Read most (opens and searches): + +- `docs/decisions.md` 14 +- `bin/task_bench/main.py` 9 +- `bin/task_bench/figures.py` 4 +- `bin/task_bench/plant.py` 4 +- `bin/task_bench/test_figures.py` 4 +- `bin/task_bench/runs.py` 3 +- `CHANGELOG.md` 2 +- `README.md` 2 +- `docs/comprehension-history.md` 2 +- `docs/score-anchors.md` 2 + +## Reading cost, chunk f8fb061b8347, finished 2026-11-22T16:17:47Z + +49961 new input tokens before the first commit. + +Read most (opens and searches): + +- `CHANGELOG.md` 2 +- `README.md` 1 +- `bin/task_bench/figures.py` 1 +- `bin/task_bench/main.py` 1 +- `bin/task_bench/test_figures.py` 1 +- `ci.sh` 1 + +## Reading cost, chunk 5e92d92c0f61, finished 2026-11-22T16:55:52Z + +63406 new input tokens before the first commit. + +Read most (opens and searches): + +- `bin/task_bench/main.py` 3 +- `docs/decisions.md` 2 +- `CHANGELOG.md` 1 +- `README.md` 1 +- `bin/task_bench/figures.py` 1 +- `bin/task_bench/test_figures.py` 1 +- `ci.sh` 1 + +## Reading cost, chunk 756ad55ec2e9, finished 2026-11-22T20:42:27Z + +89968 new input tokens before the first commit. + +Read most (opens and searches): + +- `bin/task_bench/figures.py` 3 +- `docs/decisions.md` 3 +- `README.md` 2 +- `bin/task_bench/main.py` 2 +- `bin/task_bench/runs.py` 2 +- `ci.sh` 2 +- `bin/task_bench/bench_folder.py` 1 + +## Reading cost, chunk 55d6a4a1c134, finished 2026-11-23T00:01:27Z + +96728 new input tokens before the first commit. + +Read most (opens and searches): + +- `bin/task_bench/main.py` 7 +- `bin/task_bench/test_task_bench.py` 4 +- `README.md` 2 +- `bin/task_bench/plant.py` 2 +- `bin/task_bench/runs.py` 2 +- `docs/decisions.md` 2 +- `CHANGELOG.md` 1 + +## Reading cost, chunk 5c33cc8bf84f, finished 2026-11-23T13:17:23Z + +41140 new input tokens before the first commit. + +## Reading cost, chunk 0a5c0968dbc6, finished 2026-11-23T17:38:22Z + +100034 new input tokens before the first commit. + +Read most (opens and searches): + +- `bin/project_config/settings.py` 6 +- `bin/task_bench/main.py` 6 +- `README.md` 4 +- `rules/todo-items.md` 4 +- `bin/task_bench/plant.py` 2 +- `bin/project_config/main.py` 1 +- `bin/task_bench/digest.py` 1 +- `bin/task_bench/gather.py` 1 +- `bin/task_bench/runs.py` 1 +- `docs/score-anchors.md` 1 + +## Reading cost, chunk bd47f57bf095, finished 2026-11-23T20:07:34Z + +98358 new input tokens before the first commit. + +Read most (opens and searches): + +- `rules/todo-items.md` 4 +- `bin/task_bench/main.py` 3 +- `docs/score-anchors.md` 3 +- `bin/task_bench/runs.py` 2 +- `README.md` 1 +- `bin/project_config/settings.py` 1 +- `bin/task_bench/bench_folder.py` 1 +- `bin/task_bench/plant.py` 1 + +## Reading cost, chunk 9f55b55f1c4c, finished 2026-11-23T21:54:58Z + +97426 new input tokens before the first commit. + +Read most (opens and searches): + +- `bin/task_bench/main.py` 4 +- `bin/mutate_changes/in_diff_tools.py` 2 +- `bin/task_bench/plant.py` 2 +- `bin/mutate_changes/changed_lines.py` 1 +- `bin/task_bench/runs.py` 1 +- `docs/score-anchors.md` 1 + +## Reading cost, chunk 33264f8a9040, finished 2026-11-23T22:13:25Z + +64108 new input tokens before the first commit. + +Read most (opens and searches): + +- `README.md` 3 +- `docs/decisions.md` 3 +- `skills/larv-review/SKILL.md` 3 +- `bin/task_bench/main.py` 2 +- `CHANGELOG.md` 1 +- `todo.md` 1 From 380e16de6d4e0b2d7da3d0a6a8bb337456c55114 Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:18:40 +0100 Subject: [PATCH 02/13] =?UTF-8?q?Answer=20prose=20round=201:=200=20?= =?UTF-8?q?=F0=9F=94=B4,=201=20=F0=9F=9F=A1=20(0=20misread);=20the=20bulle?= =?UTF-8?q?t=20gives=20one=20example=20per=20collision,=20joined=20segment?= =?UTF-8?q?s=20and=20shared=20prefixes,=20and=20says=20resolves?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- agents/stability-reviewer.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/agents/stability-reviewer.md b/agents/stability-reviewer.md index 6c377ab4..5beafbc8 100644 --- a/agents/stability-reviewer.md +++ b/agents/stability-reviewer.md @@ -73,7 +73,7 @@ Catch behavior that is unclear or under-specified — "building in ambiguousness - Zero and absent are different values: `empty('0')`, `if ($amount)`, `$x ?: $default`, JS `||` conflate them one way; null coerced to `'0'` conflates them the other (a past prod bug: phantom 0-amount reversals). Both directions are findings. - Multibyte text (åäö): truncation, length checks, and comparisons must be mb-safe; encoding consistent end-to-end. - Where the change splits text on a separator or strips a suffix, look in the fixtures and a sample of the source data for a value where the separator or suffix also occurs as data, such as an address split on `,` whose last part holds a comma. Report a row the parse then misplaces or drops, silently or with only a log line. -- Where the change builds a lookup key by joining path segments, or matches a key by prefix, look for two inputs that give one key, such as a segment equal to its parent's name or a namespace that is a dot-prefix of another (`ns` and `ns.sub`). Report the input the lookup credits to the wrong entry. +- Where the change builds a lookup key by joining path segments, look for two inputs that join to one key, such as a column named like its own table. Where it matches a key by prefix, look for a key that two prefixes match, such as `ns` and `ns.sub`. Report the input the lookup resolves to the wrong entry. - Are payload and collection sizes bounded at the boundary? ### 6. Concurrency & State Management From a7d178446b47871928326fc52fb2992216c76248 Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:20:46 +0100 Subject: [PATCH 03/13] Finish item 512 in the plan --- CHANGELOG.md | 1 + todo.md | 8 -------- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8008b79e..1eed6db3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ## Unreleased +- The stability reviewer now checks a lookup key built by joining path segments, or matched by prefix, for two inputs that give one key, such as a column named like its own table or the namespaces `ns` and `ns.sub`. - The release review now goes over a project's bench features: it reapplies each reference patch and rewrites one that no longer applies, deletes a feature that no longer breaks a goal, and adds features until each place the comprehension seats find hardest has one. - `task-bench` plants bugs in Python files too, from the mutants mutmut 3 kills, and tells Haiku the error pytest prints. Where the seats' places name both Go and Python files, one `--prefix` runs both tools; `task-bench --help` shows one. - `task-bench --tasks data-sources` benches adding a data source: Haiku gets a made-up register that the task's seeded `generate-register` writes, and acceptance tests check the importer, the data and whatever else the spec asks. diff --git a/todo.md b/todo.md index fc3e7456..0627101c 100644 --- a/todo.md +++ b/todo.md @@ -16,7 +16,6 @@ | ID | Release | Blocked by | Exempt | Item | L | E | I | R | S | Moves | Score | |---|---|---|---|---|---|---|---|---|---|---|---| -| 512 | 0.16.0 | | | **Make stability-reviewer check that keys built from path segments, or matched by prefix, cannot collide.** | 1 | 2 | 2 | 3 | 1 | 1.1 by 2 | 0.9 | | 529 | 0.16.0 | | owner | **Document a `task-bench` command for this repo in the README, with an image that holds what its tests need, so each scoring run benches it.** | 2 | 2 | 1 | 3 | 3 | 1.1 by 2 | 0.7 | | 507 | 0.16.0 | | owner | **Bench rebuilding a feature the project shipped: revert its commit at the head, hand Haiku its item tagline, and check with the tests that commit added.** | 3 | 2 | 1 | 4 | 5 | 1.1 by 3 | 0.7 | | 524 | 0.16.0 | | owner | **Write fejkdata's first six bench features, each a spec, acceptance tests in Go and a reference patch that builds it, in the `bench-tasks` folder its config names.** | 3 | 2 | 1 | 4 | 6 | 1.1 by 3 | 0.5 | @@ -115,13 +114,6 @@ ## Details -### 512. Make stability-reviewer check that keys built from path segments, or matched by prefix, cannot collide. - -An outside reviewer found two bugs in one chunk that our stability round passed. Both were lookups keyed by a path built from segments or matched by prefix, where two inputs give one key: a linked table that has a column of its own name took the column's row, and two modules whose namespaces nest (`ns` and `ns.sub`) were credited to the first prefix. Add a bullet beside the separator bullet in `agents/stability-reviewer.md` §5: where the change builds a lookup key by joining segments, or matches one by prefix, look for two inputs that give one key, such as a segment equal to its parent's name or a namespace that is a dot-prefix of another, and report the input the lookup credits to the wrong entry. - -Touches: -- `agents/stability-reviewer.md`: `### 5. Edge Cases & Input Validation` (small) - ### 529. Document a `task-bench` command for this repo in the README, with an image that holds what its tests need, so each scoring run benches it. The bench runs the tests in an image without network, and this repo's tests run on the host through `uvx`, so no image holds pytest, git and tmux today. Build one, pinned, and name it in the command. A scoring run starts the bench the README documents, so from then on each one spends Haiku runs. From 38c91606d600f8b0db1af4dcec2aadc207753ecf Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:21:11 +0100 Subject: [PATCH 04/13] Document a task-bench command for this repo, with an image that holds what its tests need --- .gitignore | 2 ++ README.md | 2 ++ task-bench-image/Dockerfile | 7 +++++++ 3 files changed, 11 insertions(+) create mode 100644 task-bench-image/Dockerfile diff --git a/.gitignore b/.gitignore index a6be36e7..729fb625 100644 --- a/.gitignore +++ b/.gitignore @@ -202,6 +202,8 @@ !stability-skip-count/ !stability-skip-count/README.md !stability-skip-count/count.py +!task-bench-image/ +!task-bench-image/Dockerfile !workflow-bench/ !workflow-bench/advisor-judge-prompt.md !workflow-bench/advisor-run-prompt.md diff --git a/README.md b/README.md index 33958389..1e242470 100644 --- a/README.md +++ b/README.md @@ -293,6 +293,8 @@ CI runs `ci.sh` on every pull request, and `main` doesn't merge anything until i To mutation-test the lines a branch changes, run `~/.claude/bin/run-heavy ~/.claude/bin/mutate-changes --prefix 'uvx --python "$(command -v python3)" --with pytest==9.2.0 --from "mutmut>=3,<4"'` in its checkout. +To bench how hard the code is to fix a bug in, run `docker build --quiet --memory 2g --memory-swap 2g -t claude-config-task-bench task-bench-image && ~/.claude/bin/task-bench --image claude-config-task-bench --test 'python -m pytest -q -p no:cacheprovider -n 4 bin --ignore=bin/adf_codec --ignore=bin/run_tests --ignore=bin/repo_checks/test_types.py --deselect bin/plan/test_touches.py::PredictedTest --deselect bin/loop_effects/test_effects.py::ChildShells'` in its checkout, under `~/.claude/bin/run-heavy`. A scoring run starts this command with `--record-figures`. The bench runs the tests in `task-bench-image/Dockerfile`'s image with no network, so the image holds Python, pytest, pytest-xdist, git and tmux. The test command leaves out what needs docker or `uvx` and the process tests that need an init; run `bin/run-tests` on the host for those. + ## Tracking a new file `.gitignore` is an allowlist. Track a file by negating it and its parent directories, then confirm with `git check-ignore -v `: diff --git a/task-bench-image/Dockerfile b/task-bench-image/Dockerfile new file mode 100644 index 00000000..8490e749 --- /dev/null +++ b/task-bench-image/Dockerfile @@ -0,0 +1,7 @@ +# The image `task-bench` runs this repo's tests in, with no network: README.md → Install documents its command. +# The python tag is ci.sh's; the pytest pins are bin/run_tests/main.py's. git and tmux are what the tests run; Debian's apt holds one version of each per release, so the base's tag pins them. +FROM python:3.14.8 +RUN apt-get update \ + && apt-get install --yes --no-install-recommends git tmux \ + && rm -rf /var/lib/apt/lists/* \ + && pip install --no-cache-dir pytest==9.2.0 pytest-xdist==3.8.0 From 307b7d3c04e1a11f4828cfb659475e9b3b6a398f Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:21:22 +0100 Subject: [PATCH 05/13] Record the reading cost of item 529's chunk --- docs/reading-cost.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/docs/reading-cost.md b/docs/reading-cost.md index 91f2b06f..e3d29537 100644 --- a/docs/reading-cost.md +++ b/docs/reading-cost.md @@ -3508,3 +3508,16 @@ Read most (opens and searches): - `bin/task_bench/runs.py` 1 - `bin/task_bench/tasks.py` 1 - `docs/score-anchors.md` 1 + +## Reading cost, chunk 33264f8a9040, finished 2026-11-23T22:13:25Z + +64108 new input tokens before the first commit. + +Read most (opens and searches): + +- `README.md` 3 +- `docs/decisions.md` 3 +- `skills/larv-review/SKILL.md` 3 +- `bin/task_bench/main.py` 2 +- `CHANGELOG.md` 1 +- `todo.md` 1 From 81e03f2a6db749a8d727fe2a211b9300954c15cd Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:21:45 +0100 Subject: [PATCH 06/13] =?UTF-8?q?Answer=20security=20round=201:=200=20?= =?UTF-8?q?=F0=9F=94=B4,=200=20=F0=9F=9F=A1=20(0=20misread);=20no=20findin?= =?UTF-8?q?g?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From ca99ed3ef5e0032af959811425ae5bb5d84a9a03 Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:29:40 +0100 Subject: [PATCH 07/13] Pin the bench image's Python and pytest to what CI uses, and give its command a mutmut prefix and its own build step --- README.md | 2 +- bin/repo_checks/test_task_bench_image.py | 24 ++++++++++++++++++++++++ bin/run_tests/main.py | 2 +- task-bench-image/Dockerfile | 3 +-- 4 files changed, 27 insertions(+), 4 deletions(-) create mode 100644 bin/repo_checks/test_task_bench_image.py diff --git a/README.md b/README.md index 1e242470..897ab18c 100644 --- a/README.md +++ b/README.md @@ -293,7 +293,7 @@ CI runs `ci.sh` on every pull request, and `main` doesn't merge anything until i To mutation-test the lines a branch changes, run `~/.claude/bin/run-heavy ~/.claude/bin/mutate-changes --prefix 'uvx --python "$(command -v python3)" --with pytest==9.2.0 --from "mutmut>=3,<4"'` in its checkout. -To bench how hard the code is to fix a bug in, run `docker build --quiet --memory 2g --memory-swap 2g -t claude-config-task-bench task-bench-image && ~/.claude/bin/task-bench --image claude-config-task-bench --test 'python -m pytest -q -p no:cacheprovider -n 4 bin --ignore=bin/adf_codec --ignore=bin/run_tests --ignore=bin/repo_checks/test_types.py --deselect bin/plan/test_touches.py::PredictedTest --deselect bin/loop_effects/test_effects.py::ChildShells'` in its checkout, under `~/.claude/bin/run-heavy`. A scoring run starts this command with `--record-figures`. The bench runs the tests in `task-bench-image/Dockerfile`'s image with no network, so the image holds Python, pytest, pytest-xdist, git and tmux. The test command leaves out what needs docker or `uvx` and the process tests that need an init; run `bin/run-tests` on the host for those. +To bench how hard the code is to fix a bug in, build the image first, with `~/.claude/bin/run-heavy docker build --quiet --memory 2g --memory-swap 2g -t claude-config-task-bench task-bench-image`. Then run `~/.claude/bin/task-bench --image claude-config-task-bench --prefix 'uvx --python "$(command -v python3)" --with pytest==9.2.0 --from "mutmut>=3,<4"' --test 'python -m pytest -q -p no:cacheprovider -n 4 bin --ignore=bin/adf_codec --ignore=bin/run_tests --ignore=bin/repo_checks/test_types.py --deselect bin/plan/test_touches.py::PredictedTest --deselect bin/loop_effects/test_effects.py::ChildShells'` in this checkout, under `~/.claude/bin/run-heavy`. A scoring run starts it with `--record-figures` added. The bench runs the tests with no network, so the image holds everything they need. The `--test` leaves out the tests that need docker or `uvx`, and `ChildShells`, which needs `docker run --init` to reap its processes: `bin/run-tests` on the host runs those. ## Tracking a new file diff --git a/bin/repo_checks/test_task_bench_image.py b/bin/repo_checks/test_task_bench_image.py new file mode 100644 index 00000000..b8e93df4 --- /dev/null +++ b/bin/repo_checks/test_task_bench_image.py @@ -0,0 +1,24 @@ +import pathlib +import re +import sys +import unittest + +sys.path.insert(0, str(pathlib.Path(__file__).resolve().parents[1])) + +from repo_checks import ROOT +from run_tests.main import PYTEST + +DOCKERFILE = (ROOT / "task-bench-image" / "Dockerfile").read_text(encoding="utf-8") + + +class TaskBenchImage(unittest.TestCase): + def test_the_image_has_the_python_tag_that_ci_sh_runs(self): + images = re.findall(r"^FROM (python:\S+)$", DOCKERFILE, re.MULTILINE) + self.assertEqual(len(images), 1, "task-bench-image/Dockerfile starts from one python image") + # ci.sh prints its Dockerfile with printf, so the line ends in a backslash and an n. + self.assertIn(f"FROM {images[0]}\\n", (ROOT / "ci.sh").read_text(encoding="utf-8")) + + def test_the_image_installs_the_pytest_pins_that_run_tests_uses(self): + installed = set(re.findall(r"\b(pytest(?:-xdist)?==[\d.]+)", DOCKERFILE)) + pins = {word for word in PYTEST if re.fullmatch(r"pytest(?:-xdist)?==[\d.]+", word)} + self.assertEqual(installed, pins) diff --git a/bin/run_tests/main.py b/bin/run_tests/main.py index c339649a..c19420ff 100644 --- a/bin/run_tests/main.py +++ b/bin/run_tests/main.py @@ -22,7 +22,7 @@ import typing from machine_load.slots import CPUS_PER_SLOT BIN = pathlib.Path(__file__).resolve().parents[1] -# ci.sh runs this command, so its pins live here; README.md → Test's mutation command repeats the pytest pin, so change both. The workers fill one heavy slot, since run-heavy grants one. +# ci.sh runs this command, so its pins live here; README.md → Test's mutation command and task-bench-image/Dockerfile repeat the pytest pins, so change all three. The workers fill one heavy slot, since run-heavy grants one. PYTEST = ["uvx", "--python", shutil.which("python3") or sys.executable, "--with", "pytest-xdist==3.8.0", "pytest==9.2.0", "-n", str(CPUS_PER_SLOT)] SECTION = re.compile(r"^=+ (.+) =+$") TEST_HEADER = re.compile(r"^_+ .+ _+$") diff --git a/task-bench-image/Dockerfile b/task-bench-image/Dockerfile index 8490e749..6e78bb2d 100644 --- a/task-bench-image/Dockerfile +++ b/task-bench-image/Dockerfile @@ -1,5 +1,4 @@ -# The image `task-bench` runs this repo's tests in, with no network: README.md → Install documents its command. -# The python tag is ci.sh's; the pytest pins are bin/run_tests/main.py's. git and tmux are what the tests run; Debian's apt holds one version of each per release, so the base's tag pins them. +# The python tag is ci.sh's, and the pytest pins are bin/run_tests/main.py's; bin/repo_checks/test_task_bench_image.py holds them equal. git and tmux come from Debian's current apt: the tests need no exact version. FROM python:3.14.8 RUN apt-get update \ && apt-get install --yes --no-install-recommends git tmux \ From b0258ef736db569fb46850d88d876d04e7ecd21b Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:31:55 +0100 Subject: [PATCH 08/13] Sort the new check's imports --- bin/repo_checks/test_task_bench_image.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/repo_checks/test_task_bench_image.py b/bin/repo_checks/test_task_bench_image.py index b8e93df4..19f750f2 100644 --- a/bin/repo_checks/test_task_bench_image.py +++ b/bin/repo_checks/test_task_bench_image.py @@ -5,8 +5,8 @@ import unittest sys.path.insert(0, str(pathlib.Path(__file__).resolve().parents[1])) -from repo_checks import ROOT from run_tests.main import PYTEST +from repo_checks import ROOT DOCKERFILE = (ROOT / "task-bench-image" / "Dockerfile").read_text(encoding="utf-8") From 461f1a6ef16c7db292648aa8d4b88bfd0de6b9e8 Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:32:00 +0100 Subject: [PATCH 09/13] =?UTF-8?q?Answer=20stability=20round=201:=201=20?= =?UTF-8?q?=F0=9F=94=B4,=203=20=F0=9F=9F=A1=20(0=20misread);=20the=20READM?= =?UTF-8?q?E=20command=20gets=20a=20mutmut=20--prefix=20and=20its=20own=20?= =?UTF-8?q?build=20step,=20the=20Dockerfile=20and=20run-tests'=20comments?= =?UTF-8?q?=20name=20each=20other's=20pins,=20and=20a=20repo=20check=20hol?= =?UTF-8?q?ds=20them=20equal?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From 774f1275344f78c76b8b9ba497062ed122f869b9 Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:32:00 +0100 Subject: [PATCH 10/13] =?UTF-8?q?Answer=20product-owner=20round=201:=200?= =?UTF-8?q?=20=F0=9F=94=B4,=202=20=F0=9F=9F=A1=20(0=20misread);=20the=20--?= =?UTF-8?q?prefix=20and=20the=20build=20step=20are=20in=20the=20commit=20b?= =?UTF-8?q?efore?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From a4ff7de7292ab1c9efa14fee93fac67fa59bbdcc Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:32:00 +0100 Subject: [PATCH 11/13] =?UTF-8?q?Answer=20prose=20round=201:=200=20?= =?UTF-8?q?=F0=9F=94=B4,=203=20=F0=9F=9F=A1=20(0=20misread);=20the=20Docke?= =?UTF-8?q?rfile=20comment=20and=20the=20README=20paragraph=20are=20rewrit?= =?UTF-8?q?ten=20in=20the=20commit=20before?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From 38581b98be6a73994e6e4c84c84b1be36759a57e Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:33:35 +0100 Subject: [PATCH 12/13] =?UTF-8?q?Answer=20stability=20round=202:=200=20?= =?UTF-8?q?=F0=9F=94=B4,=201=20=F0=9F=9F=A1=20(0=20misread);=20the=20repo?= =?UTF-8?q?=20check=20holds=20the=20README's=20pytest=20pins=20too,=20and?= =?UTF-8?q?=20run-tests'=20comment=20names=20it=20instead=20of=20counting?= =?UTF-8?q?=20copies?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bin/repo_checks/test_task_bench_image.py | 4 ++++ bin/run_tests/main.py | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/bin/repo_checks/test_task_bench_image.py b/bin/repo_checks/test_task_bench_image.py index 19f750f2..07cadb6d 100644 --- a/bin/repo_checks/test_task_bench_image.py +++ b/bin/repo_checks/test_task_bench_image.py @@ -22,3 +22,7 @@ class TaskBenchImage(unittest.TestCase): installed = set(re.findall(r"\b(pytest(?:-xdist)?==[\d.]+)", DOCKERFILE)) pins = {word for word in PYTEST if re.fullmatch(r"pytest(?:-xdist)?==[\d.]+", word)} self.assertEqual(installed, pins) + + def test_each_pytest_pin_in_the_readme_is_the_one_run_tests_uses(self): + pinned = {word for word in PYTEST if re.fullmatch(r"pytest==[\d.]+", word)} + self.assertEqual(set(re.findall(r"\bpytest==[\d.]+", (ROOT / "README.md").read_text(encoding="utf-8"))), pinned) diff --git a/bin/run_tests/main.py b/bin/run_tests/main.py index c19420ff..b60a5271 100644 --- a/bin/run_tests/main.py +++ b/bin/run_tests/main.py @@ -22,7 +22,7 @@ import typing from machine_load.slots import CPUS_PER_SLOT BIN = pathlib.Path(__file__).resolve().parents[1] -# ci.sh runs this command, so its pins live here; README.md → Test's mutation command and task-bench-image/Dockerfile repeat the pytest pins, so change all three. The workers fill one heavy slot, since run-heavy grants one. +# ci.sh runs this command, so its pins live here; README.md → Test's mutation and bench commands and task-bench-image/Dockerfile repeat the pytest pins, and bin/repo_checks/test_task_bench_image.py fails where one differs. The workers fill one heavy slot, since run-heavy grants one. PYTEST = ["uvx", "--python", shutil.which("python3") or sys.executable, "--with", "pytest-xdist==3.8.0", "pytest==9.2.0", "-n", str(CPUS_PER_SLOT)] SECTION = re.compile(r"^=+ (.+) =+$") TEST_HEADER = re.compile(r"^_+ .+ _+$") From 5739a308b20df5bd7a5d1346b4a73c6cc26c071c Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 23 Nov 2026 23:35:58 +0100 Subject: [PATCH 13/13] Finish item 529 in the plan --- CHANGELOG.md | 1 + todo.md | 9 --------- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1eed6db3..351cc4be 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ## Unreleased +- This repo documents its own `task-bench` command in the README → Test, with `task-bench-image/Dockerfile`, an image that holds pytest, git and tmux, so each scoring run in `larv-review` benches claude-config and records its figures. - The stability reviewer now checks a lookup key built by joining path segments, or matched by prefix, for two inputs that give one key, such as a column named like its own table or the namespaces `ns` and `ns.sub`. - The release review now goes over a project's bench features: it reapplies each reference patch and rewrites one that no longer applies, deletes a feature that no longer breaks a goal, and adds features until each place the comprehension seats find hardest has one. - `task-bench` plants bugs in Python files too, from the mutants mutmut 3 kills, and tells Haiku the error pytest prints. Where the seats' places name both Go and Python files, one `--prefix` runs both tools; `task-bench --help` shows one. diff --git a/todo.md b/todo.md index 0627101c..cdcfe0da 100644 --- a/todo.md +++ b/todo.md @@ -16,7 +16,6 @@ | ID | Release | Blocked by | Exempt | Item | L | E | I | R | S | Moves | Score | |---|---|---|---|---|---|---|---|---|---|---|---| -| 529 | 0.16.0 | | owner | **Document a `task-bench` command for this repo in the README, with an image that holds what its tests need, so each scoring run benches it.** | 2 | 2 | 1 | 3 | 3 | 1.1 by 2 | 0.7 | | 507 | 0.16.0 | | owner | **Bench rebuilding a feature the project shipped: revert its commit at the head, hand Haiku its item tagline, and check with the tests that commit added.** | 3 | 2 | 1 | 4 | 5 | 1.1 by 3 | 0.7 | | 524 | 0.16.0 | | owner | **Write fejkdata's first six bench features, each a spec, acceptance tests in Go and a reference patch that builds it, in the `bench-tasks` folder its config names.** | 3 | 2 | 1 | 4 | 6 | 1.1 by 3 | 0.5 | | 530 | 0.16.0 | | owner | **Plant a mutant in a Python file whose lines end in CRLF.** | 1 | 1 | 1 | 1 | 2 | 1.1 by 1 | 0.4 | @@ -114,14 +113,6 @@ ## Details -### 529. Document a `task-bench` command for this repo in the README, with an image that holds what its tests need, so each scoring run benches it. - -The bench runs the tests in an image without network, and this repo's tests run on the host through `uvx`, so no image holds pytest, git and tmux today. Build one, pinned, and name it in the command. A scoring run starts the bench the README documents, so from then on each one spends Haiku runs. - -Touches: -- `README.md` -- `task-bench-image/Dockerfile` - ### 507. Bench rebuilding a feature the project shipped: revert its commit at the head, hand Haiku its item tagline, and check with the tests that commit added. Such tasks cost nothing to write and are realistic. A commit whose revert doesn't apply cleanly at both the base and the head is skipped.