Repository navigation
SQL fault injection in the equivalence harness (#4173); LINK COMMAREA bounded to the caller's record (#4181) - #4200
Merged
Merged
Conversation
…EA never read past the caller's record (#4181) - The precompiler keys each statement PROGRAM:LINE (its EXEC SQL's line in the file it is written in); ggsql.c and the det port's DetSql inject a planned fault (PROGRAM LINE NTH SQLCODE SQLSTATE) at that statement on both sides, log what fired, and trace what ran. - equivalence.py run --sql-faults auto (default): one more task / run per SQL statement a case executes, its first execution failing (-803 INSERT, +100 SELECT INTO, -913 the rest); CICS and batch. - A fault task that LINKs to a program the case does not run is judged up to and including that LINK, the COMMAREA bytes compared; one that reaches a named hole, or a port without DetSql, is recorded "not judged" and left out of the proof and the coverage figure. - #4181: Cobol.commarea / commareaBack give a LINK target the caller's bytes to the end of its record; a det caller passes the bytes themselves (CicsTask.link(..., area)), so a contract DTO typed from another caller's record no longer drops the bytes it does not name (GenApp ERROR-MSG's date). - Register: M2 (injected, SQLCA assumed), X6 (judged to the LINK), X10, X11. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ
Contributor
# Conflicts: # tests/tools/equivalence.py
squid-protocol
added a commit
that referenced
this pull request
Oct 3, 2026
…age before/after, our own bugs fixed, register M2/X6/X10/X11 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ
squid-protocol
added a commit
that referenced
this pull request
Oct 3, 2026
…canner, many translators (draft) (#4192) * docs(research): COBOL->Java translation, observed -- one harness, one scanner, many translators (draft) Blameless, post-hoc observational study across GitGalaxy's det and model ports, IBM WCA4Z's LGACDB01 artifact, Devin workshop ports, SENTINEL IDE, lasserre, Lightyear and an academic API-recovery study. Sections for SENTINEL I/O (#4191), Lightyear/SENTINEL harness runs and the external-fault experiment are marked pending. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ * docs(research): §10 translation strategies compared, and what each teaches Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ * docs(research): §4 SENTINEL I/O after #4193 -- agreement depends on the scanner recognising a translator's runtime vocabulary Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ * docs(research): §6/§8 filled from #4194 -- Lightyear and SENTINEL base runs, missing-file experiment; §9-§11 updated Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ * docs(research): CBACT01C in §6.1 and §7 (#4198) -- 9 Devin runs, structure against verdict; register A1/C10/L3/F3; counts 49/51 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ * docs(research): scenario count scoped to the 50-case sweep Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ * docs(research): SQL fault injection (#4200) -- instruments, Db2 coverage before/after, our own bugs fixed, register M2/X6/X10/X11 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
squid-protocol
added a commit
that referenced
this pull request
Oct 3, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ
This was referenced Oct 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #4173, Fixes #4181
SQL fault injection (#4173)
Key. Each EXEC SQL statement is keyed
PROGRAM:LINE: its line in the file it is written in, which for an INCLUDEd member is the member's own line. The precompiler writes the key into the statement table, and every det-portDetSqlcall carries the same one.Injection, both sides. A fault plan (
PROGRAM LINE NTH SQLCODE SQLSTATE) makes that execution skip Db2, with the planned SQLCODE and SQLSTATE:tests/equivalence/db2/ggsql.c($GGSQL_FAULTS) on the COBOL side,DetSql.withFaults/gitgalaxy.sqlfaults.planon the Java side. Both log what fired, and a run proves only if the same faults fired on both sides.Enumeration.
equivalence.py run --sql-faults auto|declared|none, defaultauto. Auto adds one task (CICS) or run (batch) per statement the case actually executed, its first execution failing:SET :H = VALUESA scenario may also declare its own
sql_faults, bylineor bytable+verb.Not judged, rather than faked:
#4181, and what the faults found
Cobol.commarea/commareaBacknow give the target the caller's bytes up to the end of its record, and LOW-VALUES past it (register X10).CicsTask.link(..., area)), and a det target overlays them on DFHCOMMAREA and writes back. The LGSTSQ COMMAREA now matches byte for byte.S9(8) COMPfield, so both sides date the error message01011900. They agree, so no verdict changes, but z/OS would not give that date.Coverage before → after (det sweep,
--faults all)Verification
proof_sweep.py --det-only --jobs 4: "as expected", 48/50 (the same two KNOWN_UNPROVEN). Run on the final commit.tests/cobol_mainframe,tests/cics_crucibleandtests/test_source_reads.py: 1304 passed. The newtest_sql_faults.pypasses (6 tests).ruff_audit --ciis clean.Register (
oracle_assumptions.md)reset's SQLCA: SQLERRMC empty, SQLERRD zero. -913 rolls back the statement only.🤖 Generated with Claude Code
https://claude.ai/code/session_01RZE6us7fUL6Hynk59rWLvZ