feat(resolver): explicit embedder-passthrough recognition (#301 inc 1)#315
Conversation
The BYO-OS lean-MCU dissolve pipeline (gale#89) routes cabi_realloc to an embedder-provided seam in the pulseengine:embedder WIT namespace (e.g. pulseengine:embedder/arena's __cabi_arena_realloc), satisfied downstream at native link / synth dissolve — never by a component in the fusion set. Core-module passthrough already worked, but only INCIDENTALLY (the fusion resolver runs allow_unresolved: true). avrabe's meld-side answer on #301 asked for explicit recognition instead: a future strict/aggressive resolver could otherwise silently drop or reject these seams, and a bare cabi-arena-realloc magic-name contract is collision-prone and invisible to review. Same "explicit, not auto" stance that settled #300. - Add EMBEDDER_PASSTHROUGH_NAMESPACE (pulseengine:embedder) + is_embedder_passthrough(): matches by package namespace, version-tolerant, with no prefix false-positives (embedderx / embed rejected). - resolve_component_imports_with_hints recognizes such imports as intentional passthrough — never bound to a coincidental provider, exempt from the strict-mode UnresolvedImport error. The two error sites collapse into one with an explicit embedder arm. - LS-R-17 (approved) documents the mis-bind (UCA-R-3, H-1/H-3.1) and false-rejection hazards and the namespace-recognition mitigation. Tests: ls_r_17_embedder_passthrough_survives_strict_resolution (strict resolver keeps the embedder import but still errors on a non-embedder unexported import — exemption is namespace-scoped), test_is_embedder_passthrough_recognizes_namespace_only, and test_298_fork_arena_realloc... now asserts the retained arena import is recognized by namespace. 443 lib tests pass; rivet PASS; LS gate LS-R-17 [OK]. The --output component (P2 wrap) exposure of embedder imports remains a tracked follow-up (needs a wasm-tools component new --import-passthrough fixture). Refs: #301, gale#89, pulseengine/wasm-tools#2, pulseengine/wit-bindgen#4, synth#418. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Mythos delta-pass requiredThis PR modifies one or more Tier-5 source files (per Before merge, run the Mythos discover protocol on the
Why this gate exists: LS-A-10 The gate check on this PR will pass once the label is |
LS-N verification gate✅ 58/58 approved LS entries verified
Approved Failed LS entries(none) Missing regression tests(none) Updated automatically by |
Mythos delta-pass (auto)✅ NO FINDINGS across 2 Tier-5 file(s)
Auto-run via |
Mythos delta-pass — NO FINDINGSPer
|
…315) (#316) Downstream-boundary release. Bundles: - #313 inc 1 (#314): SCPV v3 fusion premises (bounded_memory, closed_world) for scry; meld↔scry component-provenance boundary live end-to-end (scry v2.0.0 consumer, scry#63). - #301 inc 1 (#315): explicit pulseengine:embedder passthrough recognition for the gale#89 single-address-space MCU lowering (LS-R-17). Readiness audit green: rivet validate PASS, full meld-core suite passes, pre-release Mythos delta-pass satisfied by PR-time gates (provenance.rs + resolver.rs NO FINDINGS, mythos-pass-done; closed_world hardened through 3 findings). Carried gap disclosed in CHANGELOG: fuse --output component still rejects embedder passthrough (#301 inc 2, fixture-gated). Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
What
Closes the meld side of #301 inc 1: explicit recognition of embedder-provided passthrough imports in the
pulseengine:embedderWIT namespace.The BYO-OS lean-MCU dissolve pipeline (gale#89) routes
cabi_reallocto an embedder-provided seam (e.g.pulseengine:embedder/arena's__cabi_arena_realloc), satisfied downstream at native link / synth dissolve — never by a component in the fusion set.Per avrabe's meld-side answer on #301: core-module passthrough already worked, but only incidentally (the fusion resolver runs
allow_unresolved: true). A future strict/aggressive resolver could silently drop or reject these seams, and a barecabi-arena-reallocmagic-name contract is collision-prone and invisible to review. This makes the passthrough explicit — same "explicit, not auto" stance that settled #300.Changes
EMBEDDER_PASSTHROUGH_NAMESPACE(pulseengine:embedder) +is_embedder_passthrough(): matches by package namespace, version-tolerant, no prefix false-positives (embedderx/embedrejected).resolve_component_imports_with_hintsrecognizes such imports as intentional passthrough — never bound to a coincidental provider, exempt from the strict-modeUnresolvedImporterror. The two error sites collapse into one with an explicit embedder arm.Tests / gates
ls_r_17_embedder_passthrough_survives_strict_resolution— strict resolver keeps the embedder import but still errors on a non-embedder unexported import (exemption is namespace-scoped, not over-broad).test_is_embedder_passthrough_recognizes_namespace_only— namespace match incl. version suffixes; rejects look-alikes.test_298_fork_arena_realloc_...now also asserts the retained arena import is recognized by namespace (ties the real fork fixture to the predicate).rivet validatePASS; LS gateLS-R-17 [OK].Scope / follow-up
The
--output component(P2 wrap) exposure of embedder imports remains a tracked follow-up — needs awasm-tools component new --import-passthrough-produced fixture (fork-domain, pulseengine/wasm-tools#2).Refs: #301, gale#89, pulseengine/wasm-tools#2, pulseengine/wit-bindgen#4, pulseengine/synth#418.
🤖 Generated with Claude Code