Promote WSLc from experimental to the stable config surface - #1063
Closed
Soham Das (SohamDas2021) wants to merge 1 commit into
Closed
Promote WSLc from experimental to the stable config surface#1063Soham Das (SohamDas2021) wants to merge 1 commit into
Soham Das (SohamDas2021) wants to merge 1 commit into
Conversation
Closes #1049 WSLc is now configured through the top-level `wslc` section instead of `experimental.wslc`, and selecting `"containment": "wslc"` no longer requires `--experimental` / `{ experimental: true }` / `SandboxRequest::set_experimental(true)`. This mirrors the Seatbelt promotion precedent. Wire + schema - Move `wslc` from `wire::Experimental` to the `MxcConfig` root, and from `experimental.rs` to `stable.rs` in the 0.9.0-alpha closed contract. - Keep `experimental.wslc` as a rejection alias so a pre-promotion config fails with an actionable migration message rather than being silently ignored. - Regenerate the two dev schemas and the two TypeScript wire oracles. Parser + dispatch - Generalize the state-aware dispatcher with `SectionRoot` (`Experimental` | `Stable`); `StatefulSandboxBackend::SECTION_ROOT` defaults to `Experimental` and only `WslcStateAwareRunner` overrides it. `ParsedStateAwareRequest` gains `stable_raw` for stable-rooted backends. - Drop the experimental gate for WSLc on both the one-shot and state-aware surfaces. TypeScript SDK - Move `wslc` out of `ContainerConfig.experimental` and off `ExperimentalBackends`; add `BACKEND_SECTION_ROOT`, the TS twin of the Rust `SectionRoot`, so envelopes are built at the right root. - Add a `wslcAvailable` probe fact end to end (Rust probe -> engine -> `wxc-exec --probe` -> SDK). Without it, removing the experimental gate unmasked the fact that `wslc` was never in `availableMethods`, which would have made the backend unreachable through the SDK. Rust SDK, corpus, harnesses and docs - Drop the `set_experimental(true)` requirement from `mxc-sdk`. - Hoist `experimental.wslc` to top-level `wslc` in 31 test configs. - Remove `--experimental` from the WSLc test harnesses. - Update the WSLc docs, schema reference, SDK READMEs, setup script and `.github/copilot-instructions.md`. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 9f02fa89-c89e-4a5d-b80d-5130252d3654
|
Azure Pipelines: There may be pipelines that require an authorized user to comment /azp run to run. |
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.
.github/copilot-instructions.md.Summary
Promotes the WSLc backend out of
experimentalonto the stable top-level config surface, following the Seatbelt promotion precedent already established in this repo.WSLc is now configured through the top-level
wslcsection instead ofexperimental.wslc, and selecting"containment": "wslc"no longer requires--experimental(CLI),{ experimental: true }(TypeScript SDK), orSandboxRequest::set_experimental(true)(Rust SDK). A build with thewslcCargo feature is still required.Closes #1049
Wire + schema
wslcfromwire::Experimentalto theMxcConfigroot, and fromexperimental.rstostable.rsin the0.9.0-alphaclosed contract (deleted fromOneShotExperimental).experimental.wslcas a rejection alias so a pre-promotion config fails with an actionable migration message ('experimental.wslc' has moved to the stable section; use top-level 'wslc' instead.) rather than being silently ignored.schemas/dev/mxc-config.schema.0.9.0-{dev,alpha}.jsonandsdk/node/src/generated/{,v0_9_0_alpha/}wire.ts.Parser + state-aware dispatch
The generic state-aware dispatcher hard-coded
experimental.<backend>.<phase>. Generalized with:SectionRoot { Experimental, Stable }, exposed asStatefulSandboxBackend::SECTION_ROOT(defaults toExperimental; onlyWslcStateAwareRunneroverrides it).ParsedStateAwareRequest.stable_raw, the presence gate for stable-rooted backends.locate_phase_fragmentnow takes the root and skips theexperimentaldescent forStable.The experimental gate is dropped for WSLc on both the one-shot and state-aware surfaces.
TypeScript SDK
wslcmoved out ofContainerConfig.experimentaland offExperimentalBackends.BACKEND_SECTION_ROOT, the TS twin of the RustSectionRoot, typed as an exhaustiveRecord<StateAwareContainmentBackend, …>so adding a backend without declaring a root is a compile error.wslcwas never inavailableMethods— the experimental error had always been thrown first and masked it. Post-promotion this would have made WSLc completely unreachable through the SDK. Added awslcAvailableprobe fact end to end (appcontainer_common::probe::ProbeFacts→mxc_engine::wslc_available()→wxc-exec --probe→platform.ts), mirroringisolationSessionAvailable.Rust SDK, corpus, harnesses, docs
set_experimental(true)requirement frommxc-sdkdocs, README, andCargo.toml.experimental.wslc→ top-levelwslcin 31 test configs (tests/configs/,tests/examples/).--experimentalfrom all WSLc test harnesses (run_wslc_all_tests.ps1,run_wslc_state_aware_tests.ps1, and the five per-scenario scripts).docs/wsl/*,docs/schema.md,docs/state-aware-lifecycle/*,sdk/node/README.md,scripts/setup-wslc.ps1, and the WSLc row in.github/copilot-instructions.md.Validation
cargo fmt --all -- --checkcargo clippy --workspace --all-targets --features wxc/wslc -- -D warningscargo test -p wxc_common -p wslc_common -p mxc_engine -p wxc -p mxc-sdk --features wxc/wslc,mxc-sdk/wslccargo test -p mxc_config_contract --features schema-gen— 707 testscd sdk/node && npm test— 283 tests, 0 failcheck-schema-versions,check-schema-codegen,check-sdk-types-codegen,check-contract-codegen,validate-configs(267 configs),check-version-sync,check-rust-toolchain-sync,check-psec-codegen,check-dotnet-errorcode-parityNotes
user/sodas/wslc-rejection-hardening), which is still open and overlaps in ~8 files. It should be rebased ontomainonce [WSLC] Reject remaining policy fields the backend cannot honor #1058 lands.StateAwareContainmentis IsolationSession-only) — a separate bug will be filed.Microsoft Reviewers: Open in CodeFlow