[codex] fix(parser): preserve named Kookus condition - #5120
Conversation
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
Parse changes introduced by this PR · 4 card(s), 8 signature(s) (baseline: main
|
matthewevans
left a comment
There was a problem hiding this comment.
Reviewed current head 24df1d582e86e0b37217548ff22cfe90bfb638cd.
The change is at the existing literal-name normalization and named-filter boundary seams, not a Kookus-only parser special case. The parse-diff shows the intended Kookus condition/body repair, with the other listed add/remove entries identical, and the added tests cover both the normalization boundary and the parsed trigger body. No blocking findings.
Summary
Fixes the Root #30 Kookus subcluster in
docs/parser-misparse-backlog.md.Root cause:
normalize_card_name_refsonly maskedcard(s) named ...literal spans, socreature named Keeper of Kookuswas allowed to self-reference-normalize the embedded source name toKeeper of ~. Then the named-filter terminator did not recognize the post-normalization, ~ ...clause boundary, so the trigger condition swallowed the trigger body into theNamedfilter.Changes:
creature named,permanent named,spell named, etc., ~ ...as the same referential named-filter boundary class as, it ....Parsed-card diff audit
Baseline:
/tmp/phase-root30-baseline.jsonAfter:
/tmp/phase-root30-after.jsonFilter:
Dragonstorm Forecaster|Hecatomb|High Marshal Arguel|Kookus|Liu Bei, Lord of Shu|Sift Through Sands|Thran Golem|Thrasta, Tempest's Roar|Wrathful Raptors|Wrathful Red Dragon|Zenos yae Galvus|capital offenseRaw changed card keys: exactly
kookus.Expected Kookus movement:
Namedfilter changes fromkeeper of ~, ~ deals 3 damage to you and attacks this turn if abletokeeper of kookus.DealDamage { amount: 3, target: Controller }followed by the until-end-of-turnMustAttackcontinuation.coverage-parse-diffreported no support-signature clusters (oracle_changed: 0).Validation
cargo fmt --all./scripts/check-parser-combinators.shgit diff --checkcargo test -p engine --features cli --lib normalize_named_object_literal_preserves_embedded_source_name -- --nocapturecargo test -p engine --features cli --lib named_filter_terminates_at_clause_boundary -- --nocapturecargo test -p engine --features cli --lib parse_kookus_named_creature_condition_preserves_literal_name_and_body -- --nocapturecargo run -p engine --features cli --bin oracle-gen -- data --filter "Dragonstorm Forecaster|Hecatomb|High Marshal Arguel|Kookus|Liu Bei, Lord of Shu|Sift Through Sands|Thran Golem|Thrasta, Tempest's Roar|Wrathful Raptors|Wrathful Red Dragon|Zenos yae Galvus|capital offense" --output /tmp/phase-root30-after.jsoncargo run -p engine --features cli --bin card-data-validate -- /tmp/phase-root30-after.jsoncargo run -p engine --features cli --bin coverage-parse-diff -- /tmp/phase-root30-baseline.json /tmp/phase-root30-after.json --markdown /tmp/phase-root30-parse-diff.md --json /tmp/phase-root30-parse-diff.jsonTilt is not running locally (
No tilt apiserver found: tilt-default), so direct cargo fallback was used.