Switch pid0 from bare Host to Membrane bootstrap#30
Merged
mikelsr merged 2 commits intofeat/membranefrom Feb 20, 2026
Merged
Conversation
pid0 now bootstraps via Membrane(WetwareSession) instead of a bare Host capability. On graft(), it receives an epoch-scoped Session containing Host + Executor through the WetwareSession extension. Host side: spawn_with_streams_rpc() creates a static epoch channel and uses build_membrane_rpc() instead of build_peer_rpc(). Guest side: build.rs compiles all three schemas (peer, membrane, stem) with src_prefix for clean output paths. lib.rs switches the bootstrap type and calls graft() to obtain the session.
Contributor
Author
|
Heads up — #31 (fix/pid0-cleanup) introduces a couple of changes that'll affect this branch when you rebase:
Should be straightforward to resolve — the rename is mechanical and the CLI change doesn't touch any of the membrane/RPC code. |
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
Membrane(WetwareSession)instead of a bareHostcapabilitygraft()to receive an epoch-scopedSessionwith Host + Executor via theWetwareSessionextensionbuild_membrane_rpc()instead ofbuild_peer_rpc()Changes
guests/pid0/build.rssrc_prefixguests/pid0/src/lib.rsMembrane(WetwareSession), callgraft(), extract executor from session extensionsrc/cell/executor.rswatch::channel::<Epoch>(), switch tobuild_membrane_rpc()Notes
Command/CommandBuilder→Cell/CellBuilderand unifies the CLI. This branch will need a rebase once Build fixes, tests, and dev ergonomics for pid0 #31 lands._epoch_txsender is intentionally unused for now; it gets promoted to aCommandfield when real epoch wiring landscell.witvsstreams.wit) blocks fullcargo checkbut is unrelatedTest plan
cargo check -p pid0 --target wasm32-wasip2passes (modulo pre-existing WIT conflict)cargo check --lib -p wwpasses