Skip to content

IDCAMS step model: DEFINE ALTERNATEINDEX / PATH and BLDINDEX (Part of #8881) - #8945

Merged
squid-shepherd[bot] merged 1 commit into
mainfrom
churn/8881-20261121T2259Z
Nov 22, 2026
Merged

squid-shepherd[bot] merged 1 commit into
mainfrom
churn/8881-20261121T2259Z

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

Part of #8881

Checklist: partial [c:7865474a] -- Java runtime and GnuCOBOL BDB alternate-key cross-check

What changed

Slice 1 of the oracle model for an IDCAMS alternate-index job (the three steps: DEFINE ALTERNATEINDEX, DEFINE PATH, BLDINDEX). det/idcams_model.py now models:

  • DEFINE ALTERNATEINDEX (alias AIX): RELATE, KEYS, RECORDSIZE, UNIQUEKEY / NONUNIQUEKEY, UPGRADE; DEFINE PATH with PATHENTRY; BLDINDEX INDATASET / OUTDATASET.
  • Reading a path (REPRO INDATASET or a DD naming it) gives the base records in alternate-key order; records with one key come out in base order (key order for a KSDS, arrival order for an ESDS).
  • A comma now separates operands (the nightly's decks use RECORDSIZE(40,40)), and DATA / INDEX component names are accepted on a cluster and an AIX.
  • Condition codes: a duplicate AIX or path name is 12 and feeds IF LASTCC / SET MAXCC.
  • tests/cobol_mainframe/test_idcams_model_8881.py runs the three steps (KSDS and ESDS bases, UNIQUEKEY with and without duplicates, record-size fit, REPRO through the path) and a refusal table. One row of test_idcams_model_8880.py is split because component operands beyond NAME are now refused by a more specific message.
  • docs/language_status/register/F6.md records the cited sections (SC23-6846-60, from memory, not re-read against the box copy), the ASSUMED items and the residual risk.

Evidence level: modelled and unit-tested on authored decks. Nothing is executed-equivalent; the oracle is this model, not z/OS.

Class / Sibling gaps

Class: an IDCAMS command whose effect depends on catalog entries other than a plain cluster (AIX, path) must either be modelled with a stated IBM outcome or refused by name. Same-mechanism siblings fixed here: DELETE of an AIX, a path or a cluster that has an AIX, REPRO output onto a path, an AIX or an indexed base, and a path read before BLDINDEX are all refused by name. Sibling gaps not modelled: PATHENTRY over a cluster, NOUPGRADE and upgrade on writes to the base, BLDINDEX by INFILE / OUTFILE, DATA / INDEX components as catalog entries (names are checked only), and the program-side alternate-key lookup (#4894).

Remaining slices

Facts checked

  • The TRANIDX decks (STEP20 / STEP25 / STEP30) were read from the burned CardDemo corpus; the test decks copy their shape (commas, DATA / INDEX, continuations).
  • IDCAMS SYSIN is cut at column 72 in the model; the new decks stay inside it.
  • IBM text is quoted from memory (SC23-6846-60), not re-read.

Gates

pr_gates.py --fast 9/9, --ratchets 9 pass, audit_check.py clean (ruff, mypy, dead-key, doc-refs), pinned ruff format clean on the changed files, IDCAMS tests 211 passed.

Lessons for agents

  • IDCAMS SYSIN lines are cut at column 72 by the model: a long one-line test deck loses its closing parenthesis and fails as "an unbalanced (". Use - continuations.
  • dead_key_audit flags a string key read once through dict.get("...") when it is written through a table; share a module constant.

🤖 Generated with Claude Code

…ad in alternate-key order (Part of #8881)

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@squid-protocol squid-protocol added the shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md label Nov 21, 2026
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

@squid-shepherd
squid-shepherd Bot marked this pull request as ready for review November 21, 2026 23:22
@github-actions

Copy link
Copy Markdown
Contributor

🐦‍⬛ Muninn Security Scan

✅ No security issues found.

🐦‍⬛ Powered by Muninn · Skald Lab

@squid-shepherd
squid-shepherd Bot enabled auto-merge (squash) November 21, 2026 23:35
@squid-shepherd
squid-shepherd Bot merged commit 481e633 into main Nov 22, 2026
96 checks passed
@squid-shepherd
squid-shepherd Bot deleted the churn/8881-20261121T2259Z branch November 22, 2026 00:00
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

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