Repository navigation
test: native_groupagg_batch gets its pytest twin, and a decline shape the node stops taking is a red, not a skip (#1341) - #1485
Conversation
… the node stops taking is a red, not a skip (#1341) test_native_groupagg_batch.py carries all 69 checks by the shell's name in eight tests. Under each of twelve mutations of the grouped fold, the twin reddens exactly the shell's set of checks, by name. A query that errors is read as a value, not raised, because two of the mutations (the by-value gate and the expression-key gate dropped) make the columnar query fail. Without that the twin errored and named nothing. The shell changes in two places: - The decline arms. When the grouped node was not planned, the arm read check_skip. It never fired on 15-19, and with the node gone the gate under test is unreachable, so the skip was a silent pass. It is now a red under the arm's own name. Measured with the planner refusing a text key: the old suite reports 68 passed + 1 skipped and exits 0, the new one reddens "text key: the fold declined". - A rename. "skipped vectors: four payload columns all stay in step" read only the fold's yes/no; the next arm compares the sums. Only the fold-removal mutation reddens it, so it is now "skipped vectors: the fold ran on the four-payload arm". The suite had no ledger rows. COMPLETE gains native_groupagg_batch, and its literal tables join the loop-reader guard's list. TESTS.md section 165, cluster_tests 710 -> 718. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…twelve grouped-fold mutations (#1341) The suite had no rows. suites_not_covered 201 -> 200; census 4171 rows / 2980 never / 1191 dated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
jdatcmd
left a comment
There was a problem hiding this comment.
Approve, at 831628d.
My own mutant, different from your twelve: in the batch fold's gather (columnar_vector.c, the loop before the pgcolumnar_groupagg_lookup call at :6157), drop the NULL flag: keynulls[k] = false. That folds the NULL-key group into k = 0 on the batch path only; the row path at :6277 keeps it. PG17:
| twin | reds |
|---|---|
| shell | 9: plain, filtered, two keys, count(*) and deletes against the heap mirror; toggle-differential plain, filtered and two keys; parallel against the heap mirror |
| pytest | 4: plain, deletes, toggle-differential plain, parallel (the rest masked by first-red; it's the same set, which your carry-on runner showed) |
One thing for the ledger, not blocking. Three of those reds are rows this PR enters as never: plain: answers match the heap mirror, two keys: answers match the heap mirror and count(*): answers match the heap mirror. Your description says none of your mutations moves the seven heap-mirror oracles; this one moves three of them. If you want, merge a log from this mutant to date them (a follow-up is fine too).
Also checked: the three-dot diff holds only the 7 files in your stat. The check_skip → red change for an unplanned decline shape is the right direction: a gate that can't be reached is a red.
|
@jdatcmd Thanks, your NULL-key mutant is a good one. I reproduced it on PG18 in my parity harness. #1484 and #1486 both touch the ledger, so this PR (and #1487 on top of it) needs a restate when they land. I'll merge this mutant's log in that restate, so those three rows arrive dated. I'll also correct the description's "seven heap-mirror oracles that none of these mutations moves" to four, and post the new heads for re-approval. 🤖 Generated with Claude Code |
|
@OffgridwithJD, merging #1485 now: approved at 831628d, 15/15 green, CLEAN. #1487 follows once it's green. |
|
@OffgridwithJD, a note on order: I merged #1485 before #1484 and #1486, because #1487 is stacked on it and merging mine first would have made you restate both. So #1485 needs no restate. I'll re-anchor #1484 and #1486 on 2c661ed myself and post their new heads. The three heap-mirror rows (plain, two keys, count(*)) are still
#1487 is approved at 53543d7, and I'll merge it once its checks are green. |
…y mutation from #1485's review (#1341) jdatcmd's mutation drops the NULL-key flag in the grouped fold's gather, so the NULL group folds into k = 0 on the batch path only. Nine checks redden, and the twin reddens the same nine by name. Three entered never (plain, two keys and count(*) against the heap mirror) and are now dated; the other six gain the mutation in their history. Census 4189 rows / 2969 never / 1220 dated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@jdatcmd Item 74's next twin-less suite:
native_groupagg_batch.shgetstest_native_groupagg_batch.py, and the suite is seeded in the ledger.The twin, red first and name for name
All 69 checks by the shell's name, in eight tests. Under each of twelve mutations of the grouped fold, the twin reddens exactly the shell's set. I read that with a scratch runner that records every red and carries on, which also answers your masking note on #1482: the full set is compared, not only each test's first red.
columnar_vector.c)<>folded)Two of these make the columnar query error (by-value and expression-key). The shell names those reds through
pgc_failand an empty fold value, while the first draft of the twin raised and named nothing. Its helpers now read an error as a value.Five-major runs at head: 69/69 for the shell and 69/69 for the twin, on each of 15–19.
Two shell changes
check_skip. That never fired on 15–19, and with the node gone the gate under test is unreachable, so the skip was a silent pass. Red first, with the planner refusing a text key:68 passed + 0 failed + 1 skipped, rc 0;text key: the fold declinedis red, and the twin agrees.I also checked the add-column answer arm, which wraps the grouped query in an outer
sum, the very shape the suite warns about for float8. Its plan does keep the grouped node (row path, "Batch Fold: no"), so the arm is sound.Ledger
Census 4171 / 2980 never / 1191 dated (on main
f1fa632d), with suites_not_covered 201 → 200. 31 of the 69 checks are dated.gate --against origin/maingives rc 0, and orphan-scan finds 0. 38 arrive never:<>count, read by an ungroupedcount(*);The mutant logs come from the tree just before the rebase over #1479, which changed only lib.sh's stamp key.
Collection gives
cluster_tests 710 -> 718, and TESTS.md gets §165. The guards pass 438/438 and the grader 40/40.🤖 Generated with Claude Code