fix(jcl): //* comments reach the comment surface; COND=/MSGLEVEL/debt rules wired (#2610) - #2611
Merged
Merged
Conversation
…VEL/debt rules (#2610) prism.py: jcl's line_exclusive delimiter list is (correctly) empty -- //* is a whole-line positional prefix and every JCL statement also starts with //, so the stateless per-line stripper could never express it. Every //* comment line therefore stayed in the code stream: doc_loc was 0 for all JCL, comment_analysis (doc/ownership/debt) ran on an empty string engine-wide, and ownership only counted by accident on the wrong surface. New _strip_jcl_comments whole-line partition (line-count preserving, same slot as the cobol/fortran positional path) with a case-sensitive negative guard for the ten JES3 //*-prefixed control verbs, which are statements. jcl.py: with a live comment surface, wire the signal rules JCL has real morphology for: fragile_debt/planned_debt (shared GLOBAL_* patterns, as cobol), safety = COND= return-code tests, safety_bypasses = COND=EVEN/ ONLY (run despite abend; bounded one-level-paren scan for the combined form), telemetry = MSGLEVEL=/MSGCLASS=. cleanup (DISP DELETE) was deliberately NOT added -- DISP= already feeds io and would double-count. Golden masters re-blessed (both modes): expected diff -- every corpus .jcl's coding/doc LOC split changes, telemetry/debt signals appear on real decks, and the 3D topology reflows globally with the mass change. Found via keyword-rosetta cross-language consistency work (#2581): jcl comment_lines measured ~0 real vs 46-language median 30. Closes #2610 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PUfXMUECX4Vq1vqh9mMQqt
Contributor
squid-protocol
added a commit
that referenced
this pull request
Aug 31, 2026
…ncy capstone (§10) (#2613) jcl.md: §1/§3/§4/§6 refreshed to post-#2611 truth (16/27 rules wired, 65 strict tests; safety/safety_bypasses/telemetry/debt documented with their reasoning; cleanup/globals absences documented as deliberate decisions with the overlap rationale, not bare Nones); §9's two args proxy-imprecisions annotated as since-fixed (#2482/#2483); new §10 = the keyword-rosetta cross-language-consistency capstone -- the #2581 sweep's before/after (13R/7A -> 6R/8A) with every deviation classified by the five-cause taxonomy, so a deliberately-absent rule reads differently from an unexamined gap. language-status SKILL.md: §10 added to the doc template (when to write it, where the material lives, the taxonomy grouping); README.md index calls out jcl.md as the first finished example. Companion: keyword-rosetta PR #5 (rosetta-language-sweep skill + language_deviations.py). Claude-Session: https://claude.ai/code/session_01PUfXMUECX4Vq1vqh9mMQqt Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
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.
Closes #2610. Part of the rosetta[jcl] consistency work (#2581, epic #2560).
What
prism.py: JCL//*comments now reach the comment stream. Theline_exclusivedelimiter list for jcl is deliberately empty (//prefixes every statement too), and no positional path existed either — so for every.jcl/.prcfile ever scanned, the comment surface was structurally dead:doc_loc0,comment_analysis()(doc/ownership/debt) running on an empty string,ownershipcounting only by accident viacoding_analysison the wrong surface. New_strip_jcl_commentswhole-line partition (line-count preserving, same structural slot as the cobol/fortran positional path), with a case-sensitive negative guard keeping the ten JES3//*-prefixed control statements (//*MAIN…) in the code stream while lowercase//*main story...prose still strips.languages/jcl.py: with a live comment surface, wire the signal rules JCL has genuine morphology for:fragile_debt/planned_debt— sharedGLOBAL_*patterns (as cobol): a//* TODO///* HACKbanner in a job deck now countssafety—COND=return-code tests (step error-handling); negative lookahead excludes the bare bypass formssafety_bypasses—COND=EVEN/COND=ONLY(run the step despite a prior abend); combined formCOND=((4,LT),EVEN)counts both (it carries a real RC test and a bypass), scanned with the bounded one-level-paren idiom (ReDoS-immune, cannot escape the COND value's parens to reach an unrelatedEVENlater on the line — covered by tests)telemetry—MSGLEVEL=/MSGCLASS=(job-log verbosity/routing, JCL's observability dials)cleanup(DISP=(...,DELETE)) deliberately not added:DISP=already feedsio; ledgered as morphology in the rosetta corpus instead.Why the golden masters changed
Expected, real diff (both modes): every corpus
.jclfile's coding/doc LOC split changes (comments finally leave the code stream), telemetry/debt/safety signals appear on real decks (e.g. cics-java-jcics-samplesMSGCLASS=→ Structured Telemetry 0→2), and the 3D topology reflows globally with the corpus mass change (same shape as #2517's re-bless).Verification
pytest tests/full suite: 7167 passed (153 in the touched prism/jcl files, including new COND partition-semantics, JES3-guard, line-alignment, and 2 new ReDoS detonation tests)crucible_check.py: PASS both venvs after re-blessaudit_check.py: ruff/mypy/dead-key/ast-accuracy all clear//*lines;//*MAIN CLASS=Astays code;COND=/MSGLEVEL=counts match planted intent exactly🤖 Generated with Claude Code
https://claude.ai/code/session_01PUfXMUECX4Vq1vqh9mMQqt