summaryrefslogtreecommitdiff
path: root/docs/design.typ
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-08-25 11:05:21 -0300
committerGabriel Schneider <[email protected]>2026-08-25 12:28:58 -0300
commite5f9e172330bc4500995ddd5954ed94f94e07af6 (patch)
treeaa7c5079b4c2951cef5b5c15595d0b20bc3ae245 /docs/design.typ
parent6f48508aa08396bcf9dd4da2cab1d221bcc53f78 (diff)
downloadpardes-e5f9e172330bc4500995ddd5954ed94f94e07af6.tar.gz
pardes-e5f9e172330bc4500995ddd5954ed94f94e07af6.zip
tests: a capture is a delta and a click names its word, so a tagline edit stops rewriting the suite
Diffstat (limited to 'docs/design.typ')
-rw-r--r--docs/design.typ29
1 files changed, 28 insertions, 1 deletions
diff --git a/docs/design.typ b/docs/design.typ
index 0b545bae..8b93614e 100644
--- a/docs/design.typ
+++ b/docs/design.typ
@@ -285,11 +285,38 @@ captures the rendered grid — text, cursor, and per-cell style runs — through
its own ghostty terminal. Goldens are generated from the old binary
(`zig build snap -- --update`); the new binary must reproduce them byte for
byte (`pardes-snap pardes/zig-out/bin/pardes`). Eighteen scripts covered the
-checklist in Appendix A at the rewrite; ninety cover it and everything
+checklist in Appendix A at the rewrite; ninety-five cover it and everything
since. All pass. Determinism pins: fixed workdir paths (they
appear in tags), a controlled `$HOME` with `PS1='$ '`, `LC_ALL=C`, and a
grid-stability sync primitive instead of timing guesses.
+Two of those pins were doing damage rather than work. A capture used to restate
+the whole screen, so 82% of golden lines were a copy of the line above, every
+golden carried the topbar and a tag row, and adding one builtin word to a
+tagline rewrote 78 of them — 3,758 lines of diff for a change no test was
+about. A capture is now a *delta* against the previous capture of the same kind
+in the same script: the first is the whole screen, the rest are only the rows
+that changed. The corpus went from 16,700 lines to 5,722 and the same one-word
+edit now moves 337. A capture whose only change is the cursor is the empty
+delta its script always meant.
+
+And a click used to name a screen column, which is a coordinate into that same
+chrome. When `Newtty`, `Joincol` and `Changelog` were added, seven scripts began
+clicking the word next door — `tutor.snap` clicked `Grep`, `exec.snap` clicked
+`Newtty` where it meant `Del`, `tagbottomimage.snap` clicked blank space 176
+columns from the `Del` whose effect it asserted — and `--update` blessed the
+result, leaving 256 golden lines green while asserting the opposite of their own
+first line. A click may now name the word (`press middle @Del 2`, `@Del#2` for
+the second pane on a row, `@Save-2` for a column beside one), so the word is
+either there to be clicked or the script fails.
+
+Regeneration was the other half of that failure: `--update` captured once,
+serially, and wrote whatever it saw, which is how six wrong clicks became
+goldens. It now captures in parallel at the widest probe settings the harness
+has and then runs the ordinary verify pass over what it wrote, so a capture that
+does not reproduce is reported instead of committed (77s to 41s, and the retry
+machinery that serial update never had).
+
Three deliberate deviations surfaced by the oracle, kept after review: the
greeting `ls` waits for the exact OSC 133 B input mark after the real resize
(the prototype raced bash's startup and won only by allocator luck); shells