Skip to content

equivalence: a real DUPKEY file fault; duplicate-key faults only on IBM's commands (Part of #4623) - #5043

Merged
squid-protocol merged 3 commits into
mainfrom
churn/4623-dupkey-file-fault
Oct 13, 2026
Merged

squid-protocol merged 3 commits into
mainfrom
churn/4623-dupkey-file-fault

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

Part of #4623.

What. The harness had no DUPKEY fault, so billpay/tranadd used DUPREC "as a stand-in". IBM's pages (READ, READNEXT, READPREV, WRITE, REWRITE, DELETE, STARTBR, ENDBR) say: DUPKEY (RESP 15, RESP2 140) is a read condition, a record retrieved through a NONUNIQUEKEY alternate index with another of the same key following, and the record is delivered. DUPREC (14, RESP2 150) is WRITE / REWRITE (a unique alternate key counts), and nothing is written. The WRITE page has no DUPKEY, so DUPREC on WRITE was never a stand-in: it is IBM's WRITE condition.

Change

  • equivalence_cics.py: DUPKEY in CICS_RESP; DUP_KEY_FAULTS makes the duplicate-key conditions plannable only on IBM's commands, with IBM's RESP2 (defaulted, a wrong one refused); DUPKEY on DELETE refused by name (IBM lists it but not whether the record is deleted).
  • DUPKEY is a deferred fault on both runtimes (ggcics.c dupkey_apply, CicsTask.dupkeyOr): the read runs and its NORMAL becomes DUPKEY/140, so INTO / RIDFLD / a READ UPDATE hold are as for NORMAL. A read that finds no record never fires it (the harness already fails an unfired fault).
  • billpay and tranadd: new xref-aix-dupkey scenario (READ CXACAIX, the real non-unique AIX path); the DUPREC scenarios keep their fault, why now says it is IBM's WRITE condition.
  • Register X48 (+ rendered page).

Found by the new scenario. Both model-written ports skipped the CXACAIX record move on any RESP but 0, while the COBOL has CARD-XREF-RECORD filled on DUPKEY and goes on to write a transaction with the card number: the java-facade leg differed (TRAN-CARD-NUM blank). Both ports fixed (3 lines each), recorded in each provenance.json history; both cases re-proved (billpay 26 scenarios, tranadd 47, direct and java-facade, coverage proven).

Class (file-fault conditions the harness injects: command x documented condition x RESP2)

member status
DUPKEY READ / READNEXT / READPREV this PR (stub + CicsTask + tests; RBA browse covered in Java)
DUPREC WRITE / REWRITE this PR (RESP2 150 now defaulted, refused elsewhere)
DUPKEY / DUPREC on every other command refused by name, tested per command
DUPKEY DELETE refused (X48)
the other conditions x commands (e.g. REWRITE NOTOPEN, ENDBR IOERR) not validated here, see sibling gaps

Tests. tests/cics_crucible/test_file_fault_forms.py: parametrized command x {DUPKEY, DUPREC} sweep, both runtimes against the same plan (stub compiled with cc, CicsTask with javac): record delivered, only the planned nth, no fire on NOTFND, fault log. Passing with test_equivalence_cics / test_equivalence_faults / test_cics_runtimes (295 passed, 4 skipped).

Gates. pr_gates --fast 5/5; --ratchets 7 pass, 0 fail, 0 skipped. No parsing change: no golden bless. evidence.py status lists other CICS cases stale on harness/oracle/generator (the nightly refresh regenerates them); only billpay and tranadd were re-proved here.

Cross-repo. None. Overlaps open PRs #5035 / #5038 / #5041 on equivalence_cics.py, ggcics.c, the transaction forge and oracle_assumptions.md; they will likely merge first, then this branch merges main (X48 is free as of today; theirs are X30/38/39/44/45/47).

🤖 Generated with Claude Code

squid-protocol and others added 2 commits October 13, 2026 14:13
…duplicate-key faults only on IBM's commands (Part of #4623)

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…dd re-proven with xref-aix-dupkey (Part of #4623)

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@github-actions

Copy link
Copy Markdown
Contributor

🐦‍⬛ Muninn Security Scan

✅ No security issues found.

🐦‍⬛ Powered by Muninn · Skald Lab

@squid-protocol

Copy link
Copy Markdown
Owner Author

No description provided.

@squid-protocol
squid-protocol marked this pull request as ready for review October 13, 2026 19:24
@squid-protocol
squid-protocol merged commit aee2bf4 into main Oct 13, 2026
68 checks passed
@squid-protocol
squid-protocol deleted the churn/4623-dupkey-file-fault branch October 13, 2026 19:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant