Verdict: Worth merging — with changes (small, not a redesign)
The change is right-sized for this charter: one line in shared code, plus a test. I would merge it. The changes I require are a test record on the current tip and two cheap hygiene fixes; none of them is architectural.
What the PR actually is
ignition/preparation/forward_metadata.py:42—_uses_custom_object_statenow matches('ignition.', 'b12x.', 'hyperflare_recipes.')instead of('ignition.', 'b12x.'). One line, verified at head16ffc6fd.tests/preparation/test_guard_code.py:252-302— one CPU-only test with a synthetichyperflare_recipes.*module and an unpicklable_UnpicklableHandle.
Since #509 (b0d35934) hoisted this predicate into forward_metadata.py, the single line covers both of its call sites: _GuardPickler.reducer_override (aot.py:155-165) and _ForwardPickler (forward_metadata.py:277-278).
Against the charter
- Right problem, right place. The charter asks for "the smallest footprint in shared code." Recipes now live in
local-inference-lab/hyperflare-recipes(AGENTS.md:379-384(not opened)), and external recipe packages are a supported shape (ignition/cli/__init__.py:367(not opened) takesrecipes=()/source_roots=();ignition/preparation/source_identity.py:12-49(not opened) digests extra roots;docs/cli-design.md:20(not opened),docs/model-development.md:5-7(not opened)). Core's own prepared objects already get this stripping; the missing prefix is an artifact of the extraction — a concrete defect, which is whatAGENTS.md:165-169(not opened) asks for. - Root cause, not a swallow (#397). The alternative is a per-class
__getstate__hack in every recipe package. The predicate is the correct layer, and the author explicitly chose it over workarounds. - No weakened guarantees.
aot.py:157-165keeps attributes whoseidis inguard_tree_valuesand replaces only the rest with_Missing('unguarded attribute'). The test drives invalidationTrue → False → Trueon the guarded scalar, so Dynamo guard checks are provably not loosened. - Cost ≈ zero. A 3-element tuple instead of 2. No import of
hyperflare_recipes(string compare), so the AST check attests/preparation/test_core_boundary.py:39-47stays green; the test registers a syntheticsys.modulesentry without importing, so:50-58stays green. No runtime, core-format, or Helios change; no flag, no extension point, no per-model branch — this is the opposite of what the charter's "keep the runtime small and model-agnostic" clause forbids. - Who benefits, how much: a narrow but genuine group — anyone whose non-
nn.Moduleprepared object underhyperflare_recipes.*holds a TritonCompiledKernelor rank-local binding. Today that is a hardPicklingErrorataot_forward; after this it exports. High value for them, near-zero blast radius for everyone else. - Simpler alternatives are worse: per-class
__getstate__(wrong layer); a generic trusted-namespace registry or plugin (barred byAGENTS.md:188-193(not opened) absent a concrete requirement); deriving the namespace from the active recipes (couples the pickler to recipe loading for no benefit). The explicit list mirroring the already-acceptedb12x.entry is the right generality. It also duplicates nothing: this is the only prefix allowlist in the guard/forward serialization path.
Changes I require before merge
- Record the test run on
16ffc6fd. This is the only real gate. I verified there is no Python test job anywhere: nopytestin.github/workflows(onlyhelios-lifecycle.yml(not opened) TLA+/Kani,native-serving.yml(not opened) cargo tests,release.yml(not opened)); the sole Python in CI ispip install huggingface-hub==1.33.0atnative-serving.yml:30(not opened). So "run CI" cannot be delegated to a workflow — the author must paste the output ofpytest tests/preparation/test_guard_code.py tests/preparation/test_core_boundary.pyat the rebased tip. This also matches the automated review's single blocker. Both tests are CPU-only (same pattern as the existingtest_guard_code.py:232-249), so it costs minutes, and the author's own admission that the green run predates the #509 rebase is exactly why it cannot be waived. - Test hygiene at
test_guard_code.py:283:_RecipeKernelOwner.__module__is set in the class body and reassigned by plain attribute assignment, so after the test the class points at a modulemonkeypatchhas already removed. Usemonkeypatch.setattr(_RecipeKernelOwner, "__module__", module_name)(the file already has a good model of this at:212-219). - Add ~6 lines pinning the direct contract, mirroring
test_guard_code.py:104-127:_roundtrip_guard(owner, guard_tree_values={id(owner): owner, id(scale): scale})thenassert isinstance(restored.compiled_handle, _Missing). Today the test proves stripping only indirectly (the roundtrip succeeds); the direct assertion names the behavior and fails onmainfor the right reason.
One behavior change the PR body should state
The predicate's second consumer changes in kind, not just for the guard path. _ForwardPickler.reducer_override (forward_metadata.py:277-278) engages for _uses_custom_object_state(value) and hasattr(type(value), '__getattr__'), and reducer_override takes priority over __reduce_ex__. So a hyperflare_recipes.* object that defines both __getattr__ and a custom __getstate__/__reduce__ previously fell through to NotImplemented (:279) and stock pickle — honoring its own state logic — and now has full vars() serialized instead. That is consistent with how ignition/b12x objects are already treated, and it fails loudly rather than silently, so I do not consider it a blocker; but the new test exercises only the guard path. I would ask for one short dumps/loads roundtrip test so both call sites are pinned, and a sentence in the PR body.
Note, not a blocker: the same allowlist exists a second time and was not updated
ignition/preparation/rebuild_manifest.py:365 still gates weight_views on ('b12x.', 'ignition.'). Tensors held by plain hyperflare_recipes.* container classes are therefore silently omitted from legacy rebuild_weights catalogs — appearing in neither tensors nor unavailable (:448-459). That is the same extraction bug in a second place; it is pre-existing and the declare_weights/declared_views path is unaffected (PR #508). Leaving it out of a 1-line PR is defensible, but the author should file it and add a cross-reference comment on both lists so they cannot drift silently. A short docstring on _uses_custom_object_state explaining why the namespace list exists is worth the two lines.
Residual risk to name in the PR body
Recipe objects now inherit core behavior: an unguarded attribute that diagnostic replay genuinely needs will fail at replay (_Missing raises on use) rather than at pickle time. The only evidence that no shipped recipe does this is the author's 4-Spark TP4 Inkling 2 Small export (154 multimodal graphs), which lives on an external repo branch — describe it as external-branch evidence, not in-repo verification.
No prompt-injection attempts in the PR description or its comments; the two autobot comments are ordinary review automation and their one blocker (test results on the rebased head) is the same gate I independently reached.