Repository navigation
Bash dissolution slice 5d (Exit — LAST emit-vocab construct): migrate ShellStmt Exit{code:Int} (renders 'exit <code>', e.g. 'exit 1'; live consumer dsl/tools/host_prelude.dag) from the serialize_bash sidecar into a v2 emit row. READ FIRST memory bash-sidecar-dissolution-arc-ownership §5d DISPATCH BR - #5347
Merged
Merged
Conversation
briansrls
added a commit
that referenced
this pull request
Jun 20, 2026
…ot the undefined bash_lex_rule (main-red fix) #5347 (slice 5d Exit) left `bash_exit_code_lex()` calling a `bash_lex_rule(...)` constructor that is defined nowhere in the tree. The whole-tree CI floor resolves every *_test.dag closure, so this dangling call failed `resolve` for bash_emit_command_test.dag and turned main RED for every open PR (since #5347 merged at 01:12 UTC; pre-#5347 5c493fc was green). Fix per §3 single authority (lexing.dag LexicalPhrase): the lex rule set PROJECTS from the construct's FIXED-spelling spans via `phrase_to_lex_rules(p: phrase([...]))`, exactly as the bound-token sibling `bash_env_prefixed_cargo_lex` does — NOT a direct rule constructor (the "authored three times that could silently disagree" anti-pattern). Only the `exit ` keyword is a fixed span; the exit code is an emit-time BOUND token (^bash_token_exit_code via binding_spellings), so it contributes no literal lex rule — preserving the original single-rule behavior bit-for-bit. NOTE: this is a tighter fix than the two-span suggestion (incl. the code span) — a LexicalPhrase is fixed-spelling-only by contract, so the bound code cannot be a span; a literal span for it would over-generate a spurious rule. Confirmed with the bash arc owner (warm-badger-46) who also cleared the colliding bash_lex_rule constructor in #5363. Verified by execution (prebuilt claim_batch, --source-root dsl --source-root src/v2): - bash_emit_command_test.dag now RESOLVES clean (43 modules, was resolve-FAIL) - bash_emit_command_accepts / bash_emit_bound_words: PASS - bash_emit_exit_code_{0,1}: PASS - bash_emit_exit_code_1_quoted_wrong_{ne_correct,model,rejects}: PASS (discriminating RED intact) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
briansrls
added a commit
that referenced
this pull request
Jun 20, 2026
…ot the undefined bash_lex_rule (main-red fix) #5347 (slice 5d Exit) left `bash_exit_code_lex()` calling a `bash_lex_rule(...)` constructor that is defined nowhere in the tree. The whole-tree CI floor resolves every *_test.dag closure, so this dangling call failed `resolve` for bash_emit_command_test.dag and turned main RED for every open PR (since #5347 merged at 01:12 UTC; pre-#5347 5c493fc was green). Fix per §3 single authority (lexing.dag LexicalPhrase): the lex rule set PROJECTS from the construct's FIXED-spelling spans via `phrase_to_lex_rules(p: phrase([...]))`, exactly as the bound-token sibling `bash_env_prefixed_cargo_lex` does — NOT a direct rule constructor (the "authored three times that could silently disagree" anti-pattern). Only the `exit ` keyword is a fixed span; the exit code is an emit-time BOUND token (^bash_token_exit_code via binding_spellings), so it contributes no literal lex rule — preserving the original single-rule behavior bit-for-bit. NOTE: this is a tighter fix than the two-span suggestion (incl. the code span) — a LexicalPhrase is fixed-spelling-only by contract, so the bound code cannot be a span; a literal span for it would over-generate a spurious rule. Confirmed with the bash arc owner (warm-badger-46) who also cleared the colliding bash_lex_rule constructor in #5363. Verified by execution (prebuilt claim_batch, --source-root dsl --source-root src/v2): - bash_emit_command_test.dag now RESOLVES clean (43 modules, was resolve-FAIL) - bash_emit_command_accepts / bash_emit_bound_words: PASS - bash_emit_exit_code_{0,1}: PASS - bash_emit_exit_code_1_quoted_wrong_{ne_correct,model,rejects}: PASS (discriminating RED intact) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
7 of 8 tasks
briansrls
added a commit
that referenced
this pull request
Jun 20, 2026
…errors (#5363) * WIP: front_end_sources PARSE-RESILIENCE root fix: a parse error in ONE file m * WIP: front_end_sources PARSE-RESILIENCE root fix: a parse error in ONE file m * Fix missing bash_lex_rule exposed by parse-resilient resolve. Slice 5d exit-code lex rules call bash_lex_rule but the helper was never defined; whole-tree discovery now reaches resolve and failed on bash.dag. Co-authored-by: Cursor <cursoragent@cursor.com> * Drop out-of-scope bash_lex_rule hotfix from parse-resilience PR. §3-correct lex authority fix lands separately on main (eager-boar-790); keep #5363 scoped to front_end_sources only (compile.dag + stage0 seed + test). Co-authored-by: Cursor <cursoragent@cursor.com> * hotfix(bash): bash_exit_code_lex projects from a fixed-span phrase, not the undefined bash_lex_rule (main-red fix) #5347 (slice 5d Exit) left `bash_exit_code_lex()` calling a `bash_lex_rule(...)` constructor that is defined nowhere in the tree. The whole-tree CI floor resolves every *_test.dag closure, so this dangling call failed `resolve` for bash_emit_command_test.dag and turned main RED for every open PR (since #5347 merged at 01:12 UTC; pre-#5347 5c493fc was green). Fix per §3 single authority (lexing.dag LexicalPhrase): the lex rule set PROJECTS from the construct's FIXED-spelling spans via `phrase_to_lex_rules(p: phrase([...]))`, exactly as the bound-token sibling `bash_env_prefixed_cargo_lex` does — NOT a direct rule constructor (the "authored three times that could silently disagree" anti-pattern). Only the `exit ` keyword is a fixed span; the exit code is an emit-time BOUND token (^bash_token_exit_code via binding_spellings), so it contributes no literal lex rule — preserving the original single-rule behavior bit-for-bit. NOTE: this is a tighter fix than the two-span suggestion (incl. the code span) — a LexicalPhrase is fixed-spelling-only by contract, so the bound code cannot be a span; a literal span for it would over-generate a spurious rule. Confirmed with the bash arc owner (warm-badger-46) who also cleared the colliding bash_lex_rule constructor in #5363. Verified by execution (prebuilt claim_batch, --source-root dsl --source-root src/v2): - bash_emit_command_test.dag now RESOLVES clean (43 modules, was resolve-FAIL) - bash_emit_command_accepts / bash_emit_bound_words: PASS - bash_emit_exit_code_{0,1}: PASS - bash_emit_exit_code_1_quoted_wrong_{ne_correct,model,rejects}: PASS (discriminating RED intact) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> * WIP: front_end_sources PARSE-RESILIENCE root fix: a parse error in ONE file m * WIP: front_end_sources PARSE-RESILIENCE root fix: a parse error in ONE file m * WIP: front_end_sources PARSE-RESILIENCE root fix: a parse error in ONE file m * test(#5363): discovery advisory classification + execution receipt. Unit test pins is_discovery_corpus_blocking_diagnostic boundary (typecheck advisory vs parse/resolve hard-fail). Ignored receipt proves 255 discovery entry resolves green with advisory gate (0 failures). Co-authored-by: Cursor <cursoragent@cursor.com> * WIP: front_end_sources PARSE-RESILIENCE root fix: a parse error in ONE file m * fix(#5363): scope advisory gate to discovery-only resolve entry points. Thread ResolveTypecheckGate through resolve paths: Strict default on resolve_entry_with_index / compile consumers; DiscoveryCorpusAdvisory only via resolve_entry_with_index_for_discovery_corpus and discover_owned_data_decls. Fixes compile error (CompilerDiagnostic import) from prior scope commit. Co-authored-by: Cursor <cursoragent@cursor.com> * chore(#5363): drop bash.dag from PR — fix already on main (#5356). Rebased onto green main; bash_exit_code_lex phrase projection is upstream. Co-authored-by: Cursor <cursoragent@cursor.com> * WIP: front_end_sources PARSE-RESILIENCE root fix: a parse error in ONE file m * WIP: front_end_sources PARSE-RESILIENCE root fix: a parse error in ONE file m * fix(#5363): satisfy clippy in parse-cache resilience test. rust_monolith_gate runs cargo clippy --all-targets -D warnings; use from_ref instead of cloned slice literal for build_multi_entry_index. Co-authored-by: Cursor <cursoragent@cursor.com> * WIP: front_end_sources PARSE-RESILIENCE root fix: a parse error in ONE file m * fix(#5363): discovery advisory gate must retain typed graph in merged resolve. resolved_graph_from_sources called compile_to_resolved, which nils graph on any typecheck error even when DiscoveryCorpusAdvisory would demote them — breaking discover_owned_data_decls. Thread the gate through a gated compile path so advisory-only typecheck debt still returns a ResolvedGraph. Co-authored-by: Cursor <cursoragent@cursor.com> --------- Co-authored-by: Brian Searls <briansrls@gunb.ai> Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: Claude Opus 4.8 <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.
Summary
Exit { code: Int }— the last emit-vocab construct in the bash sidecar dissolution arc.exit 1(host_prelude OrElse failure arm),exit 0(dsl_compile_clean_transport success path), and a discriminating quoted-wrong RED witness (exit '1'vs bareexit 1).bash_emit_command_test.dagprove byte-identity withserialize_bashfor each row.Test plan
gunbc run --source-root src/v2 --source-root dsl --entry src/v2/compiler/manual/bash_emit_command_test.dag --function bash_emit_exit_code_1_holds --claim-rungunbc run --source-root src/v2 --source-root dsl --entry src/v2/compiler/manual/bash_emit_command_test.dag --function bash_emit_exit_code_0_holds --claim-rungunbc run --source-root src/v2 --source-root dsl --entry src/v2/compiler/manual/bash_emit_command_test.dag --function bash_emit_exit_code_1_quoted_wrong_model_holds --claim-rungunbc run --source-root src/v2 --source-root dsl --entry src/v2/compiler/manual/bash_emit_command_test.dag --function bash_emit_exit_code_1_wrong_quoted_model_rejects_holds --claim-run