Commit c643851
cli: say the right thing about the caller's own request
Six refusals from the audit list. None of them lost data. All of them told
somebody something untrue about what they had asked for, which is rule 3 of
this project one level down: the value and the text beside it have to agree.
recipe fmt is about the shape of a file, and now says so. Measured: --check
ends with 0 on a recipe with no version, an unknown top level key, a format
nobody registered, a typo in a target key, and a size and a boundary stated
together - all five of which validate refuses. That is the owner's decision of
2026-08-03 rather than an oversight, because a formatter that refused an
invalid recipe could not lay out one somebody is still writing. What changed
is the text: the help and the flag description now say a check before a commit
wants tfg validate beside it.
The comment in the code claimed the opposite - that the formatter turns away
the same files the rest of the tool turns away - and it was written after
fixing one case of exactly that. True of the case, false in general. This
project has no guard for that kind of prose, so the entry stays in
OBSERVATIONS after being closed.
A PNG asking for more pixels than it can hold ended with 1, which tells CI
this build is broken, for a pair of numbers the caller chose. It is 4 now, the
same as every other value a format cannot deliver. This is the class closed
for declared ranges on 2026-08-03 surviving one layer deeper: the declaration
bounds each side on its own and cannot express a limit on the two multiplied.
tfg formats png now states that limit beside both settings rather than one -
mutation caught the weaker version, because removing the sentence from width
alone left the guard green while somebody setting height still learned
nothing.
What stays open is written down: the limit lives in a sentence rather than in
the declaration, so a window built from the declaration will still offer the
pair. Giving the registry a shape for a constraint binding two settings is a
change to AR9. See O45.
--count 0 or below came back as "asks for 0 files" whatever was typed, because
anything below one produced an empty list and the message described the list
rather than the request. The recipe reader had this right and the flag path
did not.
--out pointing at a file produced two messages for one mistake, the first
saying there was nothing at a path that had something at it - the system
reports a kind of error our mapping had no sentence for.
--expected-reason did not exist. A recipe could say why an outcome was
expected and the command line could not, so a run driven by flags could never
fill the category the closed list exists to make countable. It uses the same
list rather than a second copy, exported for the purpose, because two copies
is how two surfaces drift.
zip's minimum size answered 1<<62 on any failure, on the reasoning that
refusing every size is safer than declaring a wrong minimum. It is not safer,
it is quieter: every ZIP request ever made would be refused with a message
about a minimum of 4611686018427387904 B and nothing would say why. The
condition needs the default entry format to be unregistered, which today
depends on "txt" sorting before "zip" in an import list - true, and true by
accident. It panics now, like format.Register already does for the same class.
Seven guards, each seen red first, and seven mutations. Two were caught wrong:
one did not compile once the struct literal could not be closed by a one line
swap, and one stayed green because it only removed half of what the guard
should have been asking for.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>1 parent 64b363b commit c643851
10 files changed
Lines changed: 351 additions & 45 deletions
File tree
- internal
- cli
- engine
- format
- png
- zip
- guard
- recipe
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
81 | 89 | | |
82 | 90 | | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
83 | 108 | | |
84 | 109 | | |
85 | 110 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
193 | 193 | | |
194 | 194 | | |
195 | 195 | | |
196 | | - | |
| 196 | + | |
197 | 197 | | |
198 | 198 | | |
199 | 199 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
35 | 36 | | |
36 | 37 | | |
37 | 38 | | |
| |||
48 | 49 | | |
49 | 50 | | |
50 | 51 | | |
| 52 | + | |
| 53 | + | |
51 | 54 | | |
52 | 55 | | |
53 | 56 | | |
| |||
209 | 212 | | |
210 | 213 | | |
211 | 214 | | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
212 | 225 | | |
213 | 226 | | |
214 | 227 | | |
| |||
242 | 255 | | |
243 | 256 | | |
244 | 257 | | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
245 | 273 | | |
246 | | - | |
247 | | - | |
248 | | - | |
249 | | - | |
250 | | - | |
251 | | - | |
252 | | - | |
253 | | - | |
254 | | - | |
255 | | - | |
256 | | - | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
257 | 286 | | |
258 | 287 | | |
259 | 288 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
202 | 202 | | |
203 | 203 | | |
204 | 204 | | |
205 | | - | |
| 205 | + | |
206 | 206 | | |
207 | 207 | | |
208 | 208 | | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
209 | 214 | | |
210 | 215 | | |
211 | 216 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
396 | 396 | | |
397 | 397 | | |
398 | 398 | | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
399 | 410 | | |
400 | 411 | | |
401 | 412 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
94 | 101 | | |
95 | 102 | | |
96 | 103 | | |
97 | | - | |
| 104 | + | |
98 | 105 | | |
99 | 106 | | |
100 | 107 | | |
101 | 108 | | |
102 | | - | |
| 109 | + | |
103 | 110 | | |
104 | 111 | | |
105 | 112 | | |
| |||
275 | 282 | | |
276 | 283 | | |
277 | 284 | | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
278 | 291 | | |
279 | | - | |
280 | | - | |
281 | | - | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
282 | 299 | | |
283 | 300 | | |
284 | 301 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
557 | 557 | | |
558 | 558 | | |
559 | 559 | | |
| 560 | + | |
| 561 | + | |
| 562 | + | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
| 573 | + | |
560 | 574 | | |
561 | 575 | | |
562 | 576 | | |
563 | | - | |
564 | | - | |
565 | | - | |
566 | | - | |
| 577 | + | |
567 | 578 | | |
568 | 579 | | |
569 | 580 | | |
570 | | - | |
| 581 | + | |
571 | 582 | | |
572 | 583 | | |
573 | 584 | | |
574 | 585 | | |
575 | 586 | | |
576 | | - | |
| 587 | + | |
577 | 588 | | |
578 | 589 | | |
579 | 590 | | |
0 commit comments