Skip to content

Derive stage0 generated files from emission inputs - #7609

Merged
briansrls merged 75 commits into
mainfrom
session/merry-deer-815
Aug 2, 2026
Merged

briansrls merged 75 commits into
mainfrom
session/merry-deer-815

Conversation

@gunbai-bot

@gunbai-bot gunbai-bot Bot commented Aug 1, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Replace the handwritten generated_stage0_files roster with a typed emission plan derived from parse-observed regen_input_sources module identities plus modeled compiler-support identities.
  • Keep module-to-file naming and generated-vs-seed-retained classification in .dag; classification consumes the frontier-derived crate-layout projection.
  • Enroll stage0_emit_plan_generated.dag as a committed generated artifact and prove the enrolled manifest equals the live typed derivation.
  • Keep EmitResult independent: regen rejects both modeled-but-not-produced and produced-but-unmodeled files; unavailable source identity and output-path collisions refuse before projection.
  • Extend generated-projection merge policy to emitted Rust through deterministic_generated_projection_paths, with typed duplicate-path refusal before .gitattributes emission.

The source identity host supply is a declared scaffold. Its typed dissolution trigger is generated_artifact_gate accepting a v2.compiler.source_authority.ModuleStorageIndex; it observes source only and never observes EmitResult.

Test plan

  • cargo fmt --all -- --check — passed.
  • All 11 stage0_emit_model_witness_test claims — passed, including enrolled-projection equivalence, missing/extra exact-set RED controls, unavailable-source refusal, and output-path collision refusal.
  • regen_stage0 --verify — regen_divergence_count=0; committed stage0 matches fresh self-compile.
  • generated_artifact_gate.main — passed after regenerating DESIGN.md from the merged .dag authority.
  • GitHub CI — running on the current head.

gunbc-ci-auto-heal and others added 9 commits August 1, 2026 17:18
… operator ruling

Four-case integration policy (deterministic projection / hand-authored
authority / keyed set-map / roster-naming-outputs), derivation chain with
.gitattributes and git config as projections never authority, commit-writer
admission with the 218dea6 reproduction as lane 1, landing order, and the
hard-reject bars.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ig desired state

GitattributesArtifact joins the generated-artifact registry; merge rows derive
from committed_generated_artifact_paths() and the linguist presentation-policy
row stays separate. repo_local_git_config models merge-driver and core.hooksPath
bindings with membership-reconcile + read-back argv shapes. Amends the
invert-hand-maintained census row per the 2026-08-01 conflict-policy charter.

Co-authored-by: Cursor <cursoragent@cursor.com>
Correct plan-row ordering to match generated_artifact_registry (batch_c
format/regime2 swap and other ordering drift from script generation).
Add trailing newline to expected_gitattributes() for byte-identical drift
gate parity. Drop unused imports in repo_local_git_config.

Co-authored-by: Cursor <cursoragent@cursor.com>
The witness test used a leading-line == comparison the parser rejects;
rewrite with let bindings. Add git.Core.ConfigLocalGet/Set, local-scope
read-back argv, idempotent converge_actuate, and a wet execution witness
addressing review 46452.

Co-authored-by: Cursor <cursoragent@cursor.com>
The in-repo argv helpers used FilePath without importing std.types,
which broke module parsing in regen and heal_generated_artifacts.

Co-authored-by: Cursor <cursoragent@cursor.com>
@gunbai-bot gunbai-bot Bot changed the title Lane 3: derive generated_stage0_files from the stage0 emission plan; only then extend generated-projection merge policy to emitted Rust (generated-file conflict policy charter) Derive stage0 generated files from emission inputs Aug 1, 2026
@gunbai-bot
gunbai-bot Bot marked this pull request as ready for review August 1, 2026 18:15
Brian Searls and others added 10 commits August 1, 2026 18:17
Add git.Core.ConfigLocalGetInRepo/SetInRepo and
repo_local_git_config_converge_actuate_at so the real-execution witness
calls the single actuator instead of hand-built shell apply/read-back
(review 46471). Fixture init retains a named dissolution marker only for
git init in mktemp.

Co-authored-by: Cursor <cursoragent@cursor.com>
Match corpus import discipline for git.Core service calls (review 46496).
Regenerate the heal staging line for GitattributesArtifact so auto-heal
can commit the new generated artifact.

Co-authored-by: Cursor <cursoragent@cursor.com>
Adds the heal-job step that invokes repo_local_git_config converge after
artifact regen, and regenerates DESIGN.md to document the per-clone
converge entrypoint instead of a hand-typed git config command.

Co-authored-by: Cursor <cursoragent@cursor.com>
Pre-commit/pre-push now emit idempotent git config --local installs
derived from reconcile_install_argv (same authority as the actuator).
hooksPath remains the one-time manual seed; degradation without it is
documented. Finding 2 was already closed via git.Core.InitInRepo in the
wet witness — reconcile executes through typed git.Core ops, not shell
strings.

Co-authored-by: Cursor <cursoragent@cursor.com>
Registers ci_heal_repo_local_git_config_shell_emit_scaffold and emits the
required dissolve-on comment on the generated workflow step, matching the
discipline used by other foreign-executor gunbc run transports (review 46544).

Co-authored-by: Cursor <cursoragent@cursor.com>
Closes the non-blocking review 46569 hygiene note — no coverage
change, keeps the combined witness aligned with its constituents.

Co-authored-by: Cursor <cursoragent@cursor.com>
Brian Searls and others added 8 commits August 1, 2026 19:46
The heal job's gunbc run … converge path failed typecheck because
git.Inspect.Toplevel lives in extdeps.git.inspect, not the Core import.

Co-authored-by: Cursor <cursoragent@cursor.com>
repo_local_git_config converge sets core.hooksPath; on the heal runner
that makes git push invoke pre-push, which refuses when cargo is absent
from the hook PATH. Reorder heal steps so push completes first.

Co-authored-by: Cursor <cursoragent@cursor.com>
Operator second-pass (#7605): move repo_local_git_config converge to
immediately after release-bin unpack and before the skew-guard git merge
so merge.generated-artifact.driver governs the remedy merge. Heal push
uses git -c core.hooksPath= to avoid pre-push during unattended push.
Add repo_local_git_config_clone_bootstrap rollout carrier + witness.

Co-authored-by: Cursor <cursoragent@cursor.com>
Document #7609 join seam in gitattributes_emit (merry-deer owns
deterministic_generated_projection_paths), heal push hooksPath rationale
vs lane-1 admission wall, and countable dissolve-on rows for deferred
typed read-back refusals and argv-helper cleanup.

Co-authored-by: Cursor <cursoragent@cursor.com>
# Conflicts:
#	dag/gunbc/stage0_emit_model.dag
#	dag/test/claim/v1_interpreter_primitive_surface_witness_test.dag
@gunbai-bot

gunbai-bot Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor Author

Addressing review 47261: I removed the mixed census-shrink language from stage0_source_identity_supply_hand_rust_receipt; it is now explicitly and solely an EXPLICIT-DEFERRAL receipt, with the counted growth, ROADMAP row, and concrete dissolution trigger retained.\n\nI am not converting githooks_repo_local_git_config_emit in this PR. DESIGN’s current shell-routing authority explicitly classifies git hooks as foreign executors that may render shell, while §6 permits a declared scaffold as one of the two valid landing states. This carrier derives argv exclusively from reconcile_install_argv, carries an on-carrier 🟡 dissolve-on naming the canonical bash-grammar capability, and does not create a second intent authority. The requested grammar migration is exactly that declared dissolution trigger; treating every declared scaffold as already required to be dissolved would contradict the scaffold landing rule and the operator-approved boundary for this lane. — sent from merry-deer-815

briansrls pushed a commit that referenced this pull request Aug 2, 2026
…uling 2026-08-02) (#7651)

* Generated-file conflict policy: lane charter recording the 2026-08-01 operator ruling

Four-case integration policy (deterministic projection / hand-authored
authority / keyed set-map / roster-naming-outputs), derivation chain with
.gitattributes and git config as projections never authority, commit-writer
admission with the 218dea6 reproduction as lane 1, landing order, and the
hard-reject bars.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* WIP: what is our conflict policy for generated files?

* Address review 46546: state the interim status of the invert-hand-maintained row explicitly

The amendment rides with lane 2's implementation by operator sequencing:
amending the row before the modeled policy lands would make the planning
authority assert an emitted .gitattributes while the tree's file is still
hand-authored. The charter now states the interim so no two-instructions
reading exists.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Address review 46572: anchor lane 3's carrier in the charter's typed work set

Adds gunbc.stage0_emit_model generated_stage0_files to additional_works —
it exists on main today and is lane 3's subject. Lane 4's keyed-roster
carrier is deliberately NOT cited: it does not exist on main yet, and its
on-main admission surface (commit_gate_roster) is already anchored.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Address review 46587: cite the invert-hand-maintained row symbolically

gunbc.plans.invert_hand_maintained invert_hand_maintained_body, not a
line number in the projected markdown — the charter's own §3 rule.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Encode the operator second-pass acceptance walls per lane and the corrected merge sequence

Lane 1: complete staged-index observation (population equality, observed
classification, bound provenance receipt, forgery REDs), writer bindings
as countable carriers. Lane 2: converge before the first Git consumer;
named countable clone-rollout carrier; typed read-back refusals; derived
stage0 paths feed merge attributes. Lane 3: refusal preserved through
supply->plan->generation->writer; located output-path collision refusal.
Lane 4: a live path-keyed carrier consumes keyed construction end-to-end;
canonical verdict never collapsed to Bool; coordinator sequencing note on
the deleted incident carrier.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Charter candidate-scoped gates + atomic landing admission (operator ruling 2026-08-02)

The merge-freshness program the conflict-policy charter named out of
scope: three verified defects (freeze-anchored placement subject with
false law text, missing landing-candidate validation, ProcessExit
evidence collapsed to Bool before FullLedger), the three-subject
observation split, the typed accumulated verdict, the
RunnableProcessExitClaim migration, the MergeQueueOnly/ALLGREEN landing
policy absorbing the existing GatingEnforced trigger, acceptance set
A-F, landing sequence with the queue-first sequencing bar, and the
coordinator's verification receipts and sharpenings. Step 0 recorded as
already discharged (session_dashboard enrolled; #7644 closed unmerged).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Address review 46971 (commit vs tree subjects) and repair main's stale ContentHash import

IntegrationCandidate now carries base_commit/candidate_commit as the
ancestry subjects merge-base actually computes over, with candidate_tree
retained separately as the exact-tree admission subject; freeze-law
carriers follow. Also repoints dag/extdeps/transports/rest.dag's
ContentHash import to std.content_hash — main's #7480 re-home left this
module importing from std.types, which breaks main_wet's closure on any
branch (the heal job's failure here); fix identical to #7609's.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* WIP: what is our conflict policy for generated files?

* Complete the fleet heal: seed mints the grounded ContentHash, digest.dag enrolls, regen converges

Three coupled repairs riding the charter PR because main is red without
them: (1) v1_interpreter rest_bound_invocation_value minted a bare Str
input_digest while #7480's model requires the Fnv1a64(Fnv1a64Structural)
coproduct arm — every fixture-match replay witness silently failed
(model/realization fork, hidden behind main's compile error); the seed
now mints the coproduct shape (probed empirically: positional field 0).
(2) dag/extdeps/container/oci/digest.dag gains its ExternalModelScope and
scope_carrier_paths enrollment — the unenrolled-file case the operator's
verdict named live; placement gate now ExitSuccess. (3) regenerated
extdeps_container_oci_digest.rs for the new declaration; fixed point
converges. EMITTER DEFECT FLAGGED, not fixed here: the fully-qualified
module-local reference extdeps.container.oci.digest.extdeps_external_authority_anchor
emitted as crate::extdeps_cargo::... (wrong module, E0308) — first
enrolled carrier in the emitted set exposed the dotted-path resolution
class; the declaration uses the module-local spelling and the defect
belongs to the dotted-path emitter bucket.

Local receipts: replay witnesses 9/9 PASS, placement gate ExitSuccess,
dry artifact gate ExitSuccess, regen second pass clean, build 0 errors.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Address review 47056: tree-kind carrier + HAND-RUST receipt

candidate_tree is now GitTreeObjectId — a kind-refined carrier the
implementation lane introduces in extdeps.git.object_store (which today
types even GitCommitObject.tree as generic GitObjectId; the lane
re-grounds every kind-fixed position, not a charter-local special) so a
blob or tag is unrepresentable as a landing subject. Added the HAND-RUST
GATE receipt for the v1_interpreter rest replay bridge hunk: a
model-conformance repair to an existing seed mint (no new decision
surface; dissolves with the seed's rest transport bridge), checkable by
the 6-red-then-9-green replay witness split.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Address review 47071: DefaultBranchAudit subject is GitTreeObjectId too

Same class as the IntegrationCandidate fix — every audit/admission
subject in the charter is a tree by construction. Swept the doc for
remaining generic GitObjectId type positions; the three other mentions
are prose about the generic carrier itself.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Address review 47097: verdict total over both surfaces, subject on the wrapper, receipt names lane + ROADMAP row

ExtdepsScopeVerdict gains DefaultBranchAuditCovered (the audit surface
had no faithful success result) and ExtdepsScopeRefused carries the run's
ExtdepsScopeEvaluation subject once at the wrapper — refusal arms keep
only law-local facts, the six duplicated per-arm candidate fields delete,
and the rendering law now names identities that flow forward rather than
demanding base/tree on arms that never carried them. HAND-RUST receipt
gains the explicit-deferral header naming the v1-exit lane (zero
hand-maintained Rust finish line) and the witness-realization rest-bridge
trigger, matching the compile-clean-forcecheck receipt form.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Receipt records its landing vehicle: the interpreter hunk merged via #7665

The HAND-RUST receipt opened with 'This PR touches v1_interpreter.rs',
which stopped being true when main's piecemeal heal chain (#7656/#7663/
#7665) landed the same repair and the merge dissolved this branch's
inline copy into main's factored helper. The receipt stays as the
program record of the repair's class and triggers.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

---------

Co-authored-by: gunbc-ci-auto-heal <gunbc-ci-auto-heal@users.noreply.github.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
gunbai-bot Bot pushed a commit that referenced this pull request Aug 2, 2026
Document #7609 join seam in gitattributes_emit (merry-deer owns
deterministic_generated_projection_paths), heal push hooksPath rationale
vs lane-1 admission wall, and countable dissolve-on rows for deferred
typed read-back refusals and argv-helper cleanup.

Co-authored-by: Cursor <cursoragent@cursor.com>
gunbai-bot Bot pushed a commit that referenced this pull request Aug 2, 2026
Address review 46821 / crisp-bat-830: session_worktrees stays false until a
worktree-creation actuator and receipt exist; authority note names the gap;
witness guards the missing enrollment (same shape as merry-deer #7609 @01bff762).

Co-authored-by: Cursor <cursoragent@cursor.com>
gunbai-bot Bot pushed a commit that referenced this pull request Aug 2, 2026
Document #7609 join seam in gitattributes_emit (merry-deer owns
deterministic_generated_projection_paths), heal push hooksPath rationale
vs lane-1 admission wall, and countable dissolve-on rows for deferred
typed read-back refusals and argv-helper cleanup.

Co-authored-by: Cursor <cursoragent@cursor.com>
gunbai-bot Bot pushed a commit that referenced this pull request Aug 2, 2026
Address review 46821 / crisp-bat-830: session_worktrees stays false until a
worktree-creation actuator and receipt exist; authority note names the gap;
witness guards the missing enrollment (same shape as merry-deer #7609 @01bff762).

Co-authored-by: Cursor <cursoragent@cursor.com>
briansrls added a commit that referenced this pull request Aug 2, 2026
…generated-file conflict policy) (#7605)

* WIP: Lane 2: path/integration-policy join — GitattributesArtifact derived fro

* Lane 2: emit .gitattributes from registry + model repo-local git config desired state

GitattributesArtifact joins the generated-artifact registry; merge rows derive
from committed_generated_artifact_paths() and the linguist presentation-policy
row stays separate. repo_local_git_config models merge-driver and core.hooksPath
bindings with membership-reconcile + read-back argv shapes. Amends the
invert-hand-maintained census row per the 2026-08-01 conflict-policy charter.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Fix .gitattributes registry path order and emit trailing newline

Correct plan-row ordering to match generated_artifact_registry (batch_c
format/regime2 swap and other ordering drift from script generation).
Add trailing newline to expected_gitattributes() for byte-identical drift
gate parity. Drop unused imports in repo_local_git_config.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Fix witness parse error and realize repo-local git config actuator.

The witness test used a leading-line == comparison the parser rejects;
rewrite with let bindings. Add git.Core.ConfigLocalGet/Set, local-scope
read-back argv, idempotent converge_actuate, and a wet execution witness
addressing review 46452.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Fix repo_local_git_config parse error: import FilePath.

The in-repo argv helpers used FilePath without importing std.types,
which broke module parsing in regen and heal_generated_artifacts.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Route wet witness through modeled repo-local git config actuator.

Add git.Core.ConfigLocalGetInRepo/SetInRepo and
repo_local_git_config_converge_actuate_at so the real-execution witness
calls the single actuator instead of hand-built shell apply/read-back
(review 46471). Fixture init retains a named dissolution marker only for
git init in mktemp.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Add bare extdeps.git import and heal .gitattributes in ci.yml.

Match corpus import discipline for git.Core service calls (review 46496).
Regenerate the heal staging line for GitattributesArtifact so auto-heal
can commit the new generated artifact.

Co-authored-by: Cursor <cursoragent@cursor.com>

* WIP: Lane 2: path/integration-policy join — GitattributesArtifact derived fro

* Make generated hooks the repo-local git config self-healing carrier.

Pre-commit/pre-push now emit idempotent git config --local installs
derived from reconcile_install_argv (same authority as the actuator).
hooksPath remains the one-time manual seed; degradation without it is
documented. Finding 2 was already closed via git.Core.InitInRepo in the
wet witness — reconcile executes through typed git.Core ops, not shell
strings.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Add scaffold marker to heal repo-local git config CI shell carrier.

Registers ci_heal_repo_local_git_config_shell_emit_scaffold and emits the
required dissolve-on comment on the generated workflow step, matching the
discipline used by other foreign-executor gunbc run transports (review 46544).

Co-authored-by: Cursor <cursoragent@cursor.com>

* Include converge entry witness in witness_holds aggregate.

Closes the non-blocking review 46569 hygiene note — no coverage
change, keeps the combined witness aligned with its constituents.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix: import extdeps.git.inspect for converge() toplevel resolution

The heal job's gunbc run … converge path failed typecheck because
git.Inspect.Toplevel lives in extdeps.git.inspect, not the Core import.

Co-authored-by: Cursor <cursoragent@cursor.com>

* WIP: Lane 2: path/integration-policy join — GitattributesArtifact derived fro

* fix: converge before heal skew-guard merge; add clone-bootstrap carrier

Operator second-pass (#7605): move repo_local_git_config converge to
immediately after release-bin unpack and before the skew-guard git merge
so merge.generated-artifact.driver governs the remedy merge. Heal push
uses git -c core.hooksPath= to avoid pre-push during unattended push.
Add repo_local_git_config_clone_bootstrap rollout carrier + witness.

Co-authored-by: Cursor <cursoragent@cursor.com>

* docs: record lane-3 seam ownership and named lane-2 follow-up slices

Document #7609 join seam in gitattributes_emit (merry-deer owns
deterministic_generated_projection_paths), heal push hooksPath rationale
vs lane-1 admission wall, and countable dissolve-on rows for deferred
typed read-back refusals and argv-helper cleanup.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix: heal skew-guard exclude extdeps plan; import extdeps.shell in wet witness

Address review 46704: restore missing
:(exclude)docs/plans/extdeps-modeling-preflight.md in heal AUTHORED_CONFLICTS
(alongside .gitattributes from lane 2), and re-add extdeps.shell for mktemp/cleanup
calls left after InitInRepo migration.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix: on-carrier scaffold for hook-emitted repo-local git-config converge

Address review 46717: register githooks_repo_local_git_config_emit_shell_emit_scaffold
and prefix the dissolve-on marker in emit_repo_local_git_config_converge_shell so
.githooks/pre-commit and pre-push carry the marker on-carrier (ci heal pattern).
Concat-built argv remains the declared foreign-executor interim until bash-emit.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix(ci): raise v1-compiler-tests compile gate step budget to 15m

Run 30719671973 @ 6945446 timed out at 10m on srv1-01 while Checking
v1-compiler-tests (cache hit; deps consumed the prior budget). Bump step and
build-job backstop 80m -> 85m to match ci_workflow.dag authority.

Co-authored-by: Cursor <cursoragent@cursor.com>

* chore: regenerate drifted generated artifacts (ci auto-heal)

* fix: clone-bootstrap must not claim session-worktree converge coverage

Address review 46821 / crisp-bat-830: session_worktrees stays false until a
worktree-creation actuator and receipt exist; authority note names the gap;
witness guards the missing enrollment (same shape as merry-deer #7609 @01bff762).

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix: derive git config local ops from shape_git_config_local_* argv

Address review 46871: wire git.Core.ConfigLocal{Get,Set}{,InRepo}
transport through the cited shape_git_config_local_* helpers so hook
reconcile_install_argv and actuator service ops share one executable
authority; ground in-repo shapes with leading git; witness the pairing.

Co-authored-by: Cursor <cursoragent@cursor.com>

* WIP: Lane 2: path/integration-policy join — GitattributesArtifact derived fro

* fix: escape literal braces in repo_local_git_config prose strings

Review 46871 authority note used ConfigLocal{Get,Set}{,InRepo} inside a
string literal; the parser treats bare { as interpolation. Escape braces
so regen/heal parse the module again.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix: route InitInRepo transport through shape_git_init_in_repo_argv

Address review 46904: wire git.Core.InitInRepo through the cited shape
helper (with leading git, matching ConfigLocal*InRepo) instead of an
inlined duplicate argv list.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix: regenerate ci.yml and repair witness parse error

Address review 46908: commit regenerated ci.yml from ci_workflow.dag
(heal converge before skew guard, .gitattributes staging/excludes,
git -c core.hooksPath= push, 15m compile gate). Fix witness test
leading-line == parse error with let bindings (regen/heal panic).

Co-authored-by: Cursor <cursoragent@cursor.com>

* WIP: Lane 2: path/integration-policy join — GitattributesArtifact derived fro

* fix: regenerate ci.yml/DESIGN after rebase onto main

Heal job now emits download→unpack→repo-local-git-config converge→
skew-guard→regen→commit-push (hooksPath bypass)→author-commit upload,
preserving main's AuthorCommitRequired workflow path with lane-2 converge.

Co-authored-by: Cursor <cursoragent@cursor.com>

* WIP: Lane 2: path/integration-policy join — GitattributesArtifact derived fro

---------

Co-authored-by: Brian Searls <briansearls1@gmail.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: gunbc-ci-auto-heal <gunbc-ci-auto-heal@users.noreply.github.com>
gunbc-ci-auto-heal and others added 2 commits August 2, 2026 17:07
# Conflicts:
#	dag/extdeps/git/git.dag
#	dag/gunbc/ci_spec.dag
#	dag/gunbc/ci_workflow.dag
#	dag/gunbc/generated_artifact.dag
#	dag/gunbc/generated_artifact_emit.dag
#	dag/gunbc/gitattributes_emit.dag
#	dag/gunbc/githooks_repo_local_git_config_emit.dag
#	dag/gunbc/repo_local_git_config.dag
#	dag/test/claim/ci_heal_job_witness_test.dag
#	dag/test/claim/generated_artifact_drift_test.dag
#	dag/test/claim/gitattributes_emit_witness_test.dag
#	dag/test/claim/githooks_pre_push_emit_test.dag
#	dag/test/claim/githooks_repo_local_git_config_emit_witness_test.dag
#	dag/test/claim/repo_local_git_config_witness_test.dag
The main merge combined lane-2/lane-3 authorities; hooks, ci.yml, and
DESIGN.md were stale against the merged state (witness_committed_is_fixed_point
red). main_wet regenerated them; .gitattributes was already consistent.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@gunbai-bot

gunbai-bot Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor Author

Took over per operator request (author session archived). Resolved the main merge — the broad conflict set arrived because lane 2 (#7605) merged into main while this branch carried a parallel pre-squash copy of the same machinery. Resolution discipline, per the conflict-policy charter:

  • Lane-2 carriers and shared infra (repo_local_git_config.dag, githooks_repo_local_git_config_emit.dag, git.dag argv helpers, ci_spec.dag/ci_workflow.dag heal step, their witnesses): took main's merged, review-hardened versions — this branch's copies were earlier drafts, including the -C-without-git argv helpers that main's follow-up note explicitly critiques.
  • Lane-3 deliverables (Stage0EmitPlanGeneratedDagArtifact registry rows, ArtifactGenerationOutcome typed refusal, deterministic_generated_projection_paths population with duplicate-path refusal, the outcome-typed gitattributes_emit + its 139-line witness superset): kept this branch's — main's own gitattributes_emit authority note anticipates exactly this handoff by name ("until lane 3 (Derive stage0 generated files from emission inputs #7609)…").
  • Committed projections (hooks, ci.yml, DESIGN.md): stale against the merged authorities — regenerated via main_wet (charter row 1: never hand-resolved). .gitattributes was already consistent.

Verified by execution on the merged tree: build 0 errors; regen_stage0 converges with zero drift; witnesses — generated_artifact_drift_test 9/9 (including the previously-red witness_committed_is_fixed_point), gitattributes_emit_witness_test 9/9, stage0_emit_model_witness_test 11/11, v1_interpreter_primitive_surface_witness_test 21/21, repo_local_git_config_witness_test 11/11.

— sent from crisp-bat-830

# Conflicts:
#	dag/gunbc/stage0_emit_model.dag
#	dag/test/claim/stage0_emit_model_witness_test.dag
@gunbai-bot

gunbai-bot Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor Author

Second main integration (main moved during CI: #7673/#7674/#7676). The conflict was lane 3's roster deletion vs main's #7673 edits beside it: took the derived-projection shape and grafted main's two new witnesses onto it — w_occurrence_binding_identity_emit_enrolled_generated (the new std_occurrence_identity.rs must classify generated, which the plan now derives) and w_generated_file_count_floor_holds (≥112). Verified by execution: build clean, regen_stage0 converges (113 files, zero drift), stage0_emit_model_witness_test 13/13, generated_artifact_drift_test 9/9. — sent from crisp-bat-830

…; drop the tree-copied count floor; repoint the scaffold import

(1) ci_heal_skew_excluded_pathspec_words now maps committed generated
artifacts PLUS the plan-derived stage0 Rust surface (enrolled
stage0_emit_plan_generated projection prefixed by stage0_canonical_repo_path),
so a skew conflict on an emitted stage0 file is a generated-projection
conflict, never AUTHORED_CONFLICTS — heal classification and merge
policy read one authority. The enrolled read is deliberate: the emitter
needs a total surface; the drift gate enforces enrolled == derived and
the duplicate/supply refusals guard at the generation seam. (2)
w_generated_file_count_floor_holds deleted — a live-population >= 112
floor is the DESIGN §5 tree-copied census pin; the identity-grain
oracles (plan-derivation agreement witness, regen's independent
EmitResult exact-set RED) are the valid checks, and
generated_stage0_file_count stays for its identity-grain consumer in
the scaffold witness. (3) stage0_rust_source_lifecycle_scaffold imports
generated_stage0_files from its single authority
gunbc.stage0_emit_plan_generated, matching its own authority_ref.

Witnesses: stage0_emit_model 12/12, scaffold 28/28, drift 9/9,
ci_heal_job 19/19; artifact heal converges.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@gunbai-bot

gunbai-bot Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor Author

All three findings from review 47515 addressed at e7b96bf:

  1. Heal/merge-policy agreement — ci_heal_skew_excluded_pathspec_words now builds from the full merge=generated-artifact population: committed generated artifacts plus the plan-derived stage0 Rust surface. The stage0 half reads the enrolled gunbc.stage0_emit_plan_generated projection (prefixed via stage0_canonical_repo_path, the same single authority the plan rows use) rather than the refusing live derivation, because the emitter needs a total surface — the drift gate enforces enrolled == derived, and the duplicate/supply refusals guard at the generation seam, so the enrolled read inherits those guarantees without threading a second refusal channel through ci.yml emission. A note on the carrier records this reasoning.
  2. Count floor deleted — w_generated_file_count_floor_holds was the DESIGN §5 tree-copied census pin (a live-population >= 112 with no fixture, external authority, or closed-universe identity join). The valid oracles stand: w_enrolled_manifest_equals_typed_emission_plan_derivation (identity join) and regen's independent exact-set RED. generated_stage0_file_count itself stays — the scaffold witness consumes it in an identity-grain comparison. The occurrence-identity enrollment witness grafted from main is kept (identity-grain, valid).
  3. Scaffold import repointed — stage0_rust_source_lifecycle_scaffold now imports generated_stage0_files from gunbc.stage0_emit_plan_generated, matching its own generated_stage0_files_authority_ref.

Verified by execution: stage0_emit_model_witness_test 12/12 · stage0_rust_source_lifecycle_scaffold_witness_test 28/28 · generated_artifact_drift_test 9/9 · ci_heal_job_witness_test 19/19 · artifact heal converges (ci.yml regenerated with the widened exclusion set).

— sent from crisp-bat-830

…ulation

ci_heal_skew_guard_excludes_every_registered_artifact_holds folds
ci_heal_skew_excluded_paths() (identity join over the whole population);
new ci_heal_skew_guard_excludes_stage0_emitted_rust_holds discriminates
the widening (dropping the stage0 half goes red); the roster witness
asserts words == paths at identity grain and strictly-larger-than-
committed instead of the stale count equality that would have redded CI.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@gunbai-bot

gunbai-bot Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor Author

review 47522 addressed at the new head: ci_heal_skew_guard_excludes_every_registered_artifact_holds now folds ci_heal_skew_excluded_paths() (the full population, identity join); added ci_heal_skew_guard_excludes_stage0_emitted_rust_holds as the discriminating witness — dropping the stage0 half from the exclusion population goes red, closing the regression-greens-the-test hole the review named; the roster witness asserts words == paths at identity grain plus strictly-larger-than-committed, replacing the stale count equality. 16/16 PASS by execution. — sent from crisp-bat-830

@briansrls
briansrls merged commit 93979eb into main Aug 2, 2026
5 checks passed
@briansrls
briansrls deleted the session/merry-deer-815 branch August 2, 2026 21:28
gunbai-bot Bot pushed a commit that referenced this pull request Aug 2, 2026
Regenerate generated_stage0_files and gitattributes rows for std_keyed_roster/row so the enrolled projection matches the parse-derived emission closure.

Co-authored-by: Cursor <cursoragent@cursor.com>
gunbai-bot Bot pushed a commit that referenced this pull request Aug 2, 2026
Land R1 dispatch inversion on current main: .dag roster is the sole
authority, emit derives Rust lookup tables, and stage0 source-identity
scaffold from #7609 is preserved in roster, generated lookup, and witness.

Co-authored-by: Cursor <cursoragent@cursor.com>
gunbai-bot Bot pushed a commit that referenced this pull request Aug 2, 2026
Regenerate generated_stage0_files and gitattributes rows for std_keyed_roster/row so the enrolled projection matches the parse-derived emission closure.

Co-authored-by: Cursor <cursoragent@cursor.com>
gunbai-bot Bot pushed a commit that referenced this pull request Aug 3, 2026
Land R1 dispatch inversion on current main: .dag roster is the sole
authority, emit derives Rust lookup tables, and stage0 source-identity
scaffold from #7609 is preserved in roster, generated lookup, and witness.

Co-authored-by: Cursor <cursoragent@cursor.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant