Commit 19f29a5
fix(python-cli): verify --templates enforces @requiredSlots/@requiredTags (#230)
Python's `verify --templates` never passed required_slots/required_tags to the render
verify() engine, so a `template.prompt` whose body omits a `@requiredTags` output tag
passed verify (exit 0) while TS/Java/C# failed it — a cross-port parity gap (surfaced
during the #193 review). The `if e.code == ERR_REQUIRED_SLOT_UNUSED: continue` branch
could never even fire.
Now the prompt path threads @requiredSlots/@requiredTags (resolving read, ADR-0039 — an
inherited value is honored) into render_verify: a missing required output tag →
ERR_OUTPUT_TAG_MISSING (drift, fails); an unused required slot → ERR_REQUIRED_SLOT_UNUSED
(warning). Kept prompt-only — the email/document output gate does not apply them per-part
(the #193 cross-port consensus). Error line generalized to `{code}: {path}` (was
payload-VO-specific, wrong for a missing-tag finding).
Regression tests: a @requiredTags prompt missing the tag fails; present passes.
verify-subverbs 14/14.
Closes #230.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XeGSV3StPCcJGZNNJ4ZfAb1 parent 7811a9f commit 19f29a5
2 files changed
Lines changed: 75 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
573 | 573 | | |
574 | 574 | | |
575 | 575 | | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
576 | 586 | | |
577 | 587 | | |
578 | 588 | | |
| |||
659 | 669 | | |
660 | 670 | | |
661 | 671 | | |
| 672 | + | |
| 673 | + | |
| 674 | + | |
| 675 | + | |
| 676 | + | |
| 677 | + | |
| 678 | + | |
| 679 | + | |
| 680 | + | |
| 681 | + | |
662 | 682 | | |
663 | 683 | | |
664 | 684 | | |
| |||
670 | 690 | | |
671 | 691 | | |
672 | 692 | | |
673 | | - | |
| 693 | + | |
| 694 | + | |
| 695 | + | |
| 696 | + | |
674 | 697 | | |
675 | | - | |
| 698 | + | |
676 | 699 | | |
677 | | - | |
678 | | - | |
| 700 | + | |
679 | 701 | | |
680 | 702 | | |
681 | 703 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
196 | 196 | | |
197 | 197 | | |
198 | 198 | | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
199 | 248 | | |
200 | 249 | | |
201 | 250 | | |
| |||
0 commit comments