Skip to content

[WSLC] Bump WSLc SDK to 3.0.3 - #1550

Merged
Soham Das (SohamDas2021) merged 1 commit into
mainfrom
sohamdas2021-wslc-sdk-3-0-3-bump
Oct 21, 2026
Merged

Soham Das (SohamDas2021) merged 1 commit into
mainfrom
sohamdas2021-wslc-sdk-3-0-3-bump

Conversation

@SohamDas2021

@SohamDas2021 Soham Das (SohamDas2021) commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

📖 Description

Updates the pinned WSLc SDK from 2.9.9 to 3.0.3. 3.0.3 adds WslcSetProcessSettingsFlags with WSLC_PROCESS_FLAG_STDIN, which lets a caller open a container process's stdin. MXC does not forward stdin yet; that comes in the next PR.

🔗 References

Fixes #1585.
Part of #1258. Upstream: microsoft/WSL#41698.

🔍 Validation

  • cargo fmt --all -- --check: passed
  • cargo clippy --workspace --all-targets -- -D warnings: passed
  • cargo clippy -p mxc-sdk --features wslc --all-targets -- -D warnings: passed
  • cargo test --workspace: 4257 passed, 0 failed
  • cargo test -p mxc-sdk --features wslc --lib wslc::common: 360 passed
  • cargo test -p mxc-sdk --features wslc --test wslc_stdin_handle_probe -- --ignored: passed. Without the flag, stdin returns E_INVALIDARG. With it, stdin returns S_OK, including when callbacks are registered, and data written to stdin comes back through cat. Against the 2.9.9 DLL, loading fails as expected.
  • tests\scripts\run_wslc_all_tests.ps1 (x64 release, WSL 3.0.4): 40/40 before and after. The state-aware suite inside it is 123/123 before and after.
  • Not run: ARM64 (no host).

✅ Checklist

📋 Issue Type

  • Bug fix
  • Feature
  • Task

GitHub Actions runs the PR validation build automatically. The ADO pipeline
(MXC-PR-Build) is the Azure version of the PR pipeline, kept in parity with the GitHub
Actions build; it runs on merge to main, and Microsoft reviewers with write access can trigger it
on a PR with /azp run. See pull request builds.

If the dependency-feed-check check fails on a new dependency, the crate must be added to
the feed before the PR can pass. See pull request builds
for the steps.

Microsoft Reviewers: Open in CodeFlow

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: df93958a-1870-40ab-8460-9d6e6ee75429
Copilot AI balanced review requested due to automatic review settings October 21, 2026 19:57
@SohamDas2021
Soham Das (SohamDas2021) requested a review from a team as a code owner October 21, 2026 19:57
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@SohamDas2021 Soham Das (SohamDas2021) changed the title Bump WSLc SDK (Microsoft.WSL.Containers) to 3.0.3 [WSLC] Bump WSLc SDK to 3.0.3 Oct 21, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The probe can unload the SDK while callback threads remain active, risking an access violation during teardown.

1 open issue
What changed in this PR

Updates the WSLc SDK to 3.0.3 as groundwork for #1258. MXC stdin forwarding remains unchanged.

Changes:

  • Updates the SDK pin, generated bindings, and required DLL exports.
  • Adds an ignored stdin-handle probe.
  • Updates runtime prerequisites and binding-generation guidance.
File Description
src/​mxc-sdk/​tests/​wslc_stdin_handle_probe.rs Adds handle and stdin round-trip checks.
src/​mxc-sdk/​src/​lib.rs Clarifies MXC’s stdin limitation.
src/​mxc-sdk/​src/​backends/​wslc/​common/​wslcsdk_sys.rs Adds generated process-flag bindings.
src/​mxc-sdk/​src/​backends/​wslc/​common/​wslc_bindings.rs Requires the new process-flags export.
src/​mxc-sdk/​src/​backends/​wslc/​common/​wsl_container_runner.rs Updates prerequisite-message assertions.
src/​mxc-sdk/​src/​backends/​wslc/​common/​sdk_init.rs Updates WSL installation guidance.
src/​mxc-sdk/​src/​backends/​wslc/​common/​sandbox.rs Corrects stdin documentation.
src/​mxc-sdk/​build/​wslc_common/​README.md Updates package and regeneration guidance.
src/​mxc-sdk/​build/​build_wslc_common.rs Pins SDK 3.0.3 and its checksum.
scripts/​generate-wslc-bindings.ps1 Registers process flags as bitflags.
scripts/​ci/​prepare-windows-host.ps1 Clarifies the existing update-channel comment.
docs/​development/​build-and-test/​wslc-sdk-bindings.md Updates build and probe instructions.
docs/​backends/​wslc/​wslc-state-aware.md Updates SDK version and stdin wording.
docs/​backends/​wslc/​wsl-container-getting-started.md Raises prerequisites and corrects stdin guidance.

Review effort: Balanced

// SAFETY: COM is initialised on this thread for the whole test, and every
// guard outlives the SDK calls made against the handle it owns.
unsafe {
let sdk = load_sdk_checked(&mut logger).expect("WSLc runtime unavailable");
@SohamDas2021
Soham Das (SohamDas2021) merged commit 808c8d8 into main Oct 21, 2026
31 checks passed
@SohamDas2021
Soham Das (SohamDas2021) deleted the sohamdas2021-wslc-sdk-3-0-3-bump branch October 21, 2026 22:48
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.

Update the WSLc dependency to version 3.0.3

3 participants