Skip to content

weight-sync(controller): fail-loud full source/destination coverage guard - #667

Open
lokic233 wants to merge 1 commit into
google:mainfrom
lokic233:pr-b-full-coverage-guard
Open

weight-sync(controller): fail-loud full source/destination coverage guard#667
lokic233 wants to merge 1 commit into
google:mainfrom
lokic233:pr-b-full-coverage-guard

Conversation

@lokic233

Copy link
Copy Markdown

Problem

Full-state weight publication requires every registered destination variable to have a matching source variable. Previously a destination var with no matching source was silently left stale — e.g. dst {w0, w1}, src {w0}w0 lands, w1 keeps its pre-transfer value, success == true, no raise. A partial policy is published as if complete (BUG2 class).

Fix (fail-loud coverage check)

In controller plan-generation, before emitting the transfer plan, raise if any registered destination variable has no source variable by name. Fail-loud rather than publish a partial policy. The guard sits at the plan-entry point (the chunk-emission region edited by later commits is below it), so it composes cleanly.

Validation

Deterministic unit checks: raises on the missing-var repro (w1 unmatched), passes on full coverage, skips None-named vars, no-op on empty destination. Consistent with the LANDING full-state contract.

Scope / non-goals

Catches the missing-var (BUG2) class. It does not catch the silent byte-drop of a present rank-1 var (that is the separate D2H event-completion fix). A per-byte/slice coverage tally is a documented follow-up. Not subset-sync (no stop-condition/partial-set semantics).


Authored with agentic assistance (Navi); guard logic validated deterministically and consistent with prior silicon runs.

…uard

Full-state weight publication requires every registered destination variable to
have a matching source variable. Previously a destination var with no matching
source was SILENTLY left stale (dst={w0,w1}, src={w0} -> w0 lands, w1 keeps its
pre-transfer value, success=True, no raise) — a partial policy published as if
complete (BUG2 class).

Add a name-coverage check in controller plan-generation: before emitting the
transfer plan, raise if any registered destination variable has no source var by
name. Fail-loud rather than publish a partial policy.

Deterministically validated: raises on the missing-var repro (dst w1 unmatched),
passes on full coverage, skips None-named vars, no-op on empty dst. SCOPE: this
catches the missing-var (BUG2) class; it does NOT catch the silent byte-drop of a
PRESENT rank-1 var (that is the separate D2H event-completion fix). A per-byte
coverage tally is a documented follow-up.
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