You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Forge copybook fallback: follow EXEC SQL INCLUDE and COPY … IN <library> #3414
Found by the mainframe ground-truth ledger (tests/tools/ground_truth_ledger.py, cause forge_copybook_resolution).
Problem
The forge's own copybook resolver (cobol_answer_key.old_copybooks → the forge path) misses 17 of 128 hand-verified copybook edges. The engine resolves all 128. Two shapes account for all 17:
shape
misses
example
EXEC SQL INCLUDE <member> END-EXEC is not treated as a copy
15 (CBSA)
BANKDATA.cbl → src/base/cobol_copy/ACCDB2.cpy, CONTDB2.cpy; PROCDB2.cpy from 7 programs
COPY <member> IN <library> is not resolved through the zapp.yaml library
2 (zopeneditor)
SAM1LIB.cblCOPY DATETIME IN MYFILE → COPYLIB/DATETIME.cpy, COPY REPTTOTL IN MYLIB → COPYLIB-MVS/REPTTOTL.cpy
Why it matters
When an engine DB is present, the refractor already takes copy_deps from EngineFile, so this only affects the no-DB fallback. That path should still be right: it is what runs on a program scanned without the engine.
Acceptance
The 17 forge | copybook paths | … | fn entries in tests/cobol_mainframe/ground_truth_ledger.json stop reproducing. ground_truth_ledger.py check then fails with "no longer reproduces", and update ratchets them out.
Fixture tests: one for an EXEC SQL INCLUDE, one for a COPY … IN lib resolved through zapp.yaml.
More evidence from CardDemo (answer key added alongside #3415). The forge's fallback resolver misses 17 more hand-verified copybook edges there. Three more shapes join the two already in this issue:
Activity
squid-protocol commentedon Sep 23, 2026
More evidence from CardDemo (answer key added alongside #3415). The forge's fallback resolver misses 17 more hand-verified copybook edges there. Three more shapes join the two already in this issue:
EXEC SQL INCLUDEof a DCLGEN member (.dcl)AUTHFRDS.dcl(COPAUS2C),DCLTRTYP.dcl×3,DCLTRCAT.dclEXEC SQL INCLUDE(as in the original report)CSDB2RPY,CSDB2RWY(COTRTLIC)COPY 'CSSTRPFY'.COPY CSSETATY REPLACING …/ a COPY whose period is on a later lineThe engine resolves the quoted and REPLACING forms. It misses the one-line
EXEC SQL INCLUDE(#3416) and one excluded data-only copybook (#3417).ci: mainframe ground-truth ledger, gated on every PR (#3415)
answer key: CardDemo key, verification tiers, seven draft-reader fixes (
Forge: copybook resolver reads every copy shape (#3414); schema reade…