Repository navigation
equivalence: declared_differences case field and COMP-5 oracle byte reversal in the comparator (Part of #7646) - #7725
Merged
Conversation
… COMP-5 oracle bytes when declared (Part of #7646) Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Contributor
|
No description provided. |
This was referenced Nov 4, 2026
Merged
Merged
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.
Part of #7646 (slice 3 of 3, after #7671 and #7673).
What
A case may now carry
"declared_differences": ["comp5_byte_order"]. The comparator (diff_records) then reads each COMP-5 field of 2 or more bytes of the oracle record reversed, as z/OS holds it, and compares it with the port's bytes (the z/OS image,translate(zos_comp5=True)from #7673).equivalence_common.py:DECLARED_DIFFERENCES,declared_differences(case)(unknown or repeated kind refused by name),declared_difference_records,comp5_zos_view,diff_records(..., oracle_comp5_reversed=).equivalence.py: fixed-record datasets pass the flag; the run's report carriesdeclared_differences.evidence.py:record_proofstores them as differences of kinddeclared(replaced by every proof, likeoption).tests/tools/test_equivalence_declared_differences.py(2-, 4- and 8-byte fields, negative values, COMP unchanged, a real value difference still differs, a port holding the old little-endian image is not equal under the declaration, validation).Never loosened: only the oracle side of COMP-5 fields is reversed, nothing else; an undeclared case compares as before (no port, case or record moved).
Class / Sibling gaps
Class: comparators that read a record's bytes against the oracle's, each of which must undo the declared COMP-5 byte order for a case that declares it. Handled: the fixed-record dataset comparator (
equivalence.compare_run->diff_records). Sibling gaps (same mechanism, not here: separate call sites and their own tests; a case declaring the difference there shows false differences, never a false pass): variable-recorddiff_varseq; CALL itemsequivalence_call.compare_item/compare_dto; CICS filesequivalence_cics.compare_files; IMSequivalence_ims.diff_db/diff_gsam; table comparison_compare_tables.Remaining slices
--record).Gates
pr_gates.py --fast: 9/9 PASS (lint, audits, secrets, xray, gen-docs, derived, workflows, gauntlet, affected ; ruff 0.17.2 pinned). Tree-wide guards and the new test pass (180 passed).ruff format --checkflagsevidence.pylines 1379 (an existing unformatted hunk, not touched here).Not run:
--ratchets/ golden (no engine code touched), a real equivalence proof (needs Docker/GnuCOBOL; slice 2 of "Remaining").Cross-repo
None.
🤖 Generated with Claude Code