Repository navigation
Studio: pin MXC 1.1.0 where Windows has the built-in container, fall back to 1.0.1 elsewhere - #19443
Conversation
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
@codex review |
1 similar comment
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 508a0e10c9
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
… a fallback recorded on an unreadable Windows release
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 20f7cc2a44
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…tier off on it - The installer probes the 1.1.0 candidate in its staging folder and falls back to 1.0.1 before swapping; the demotion is recorded only once 1.0.1 is installed. - A probe that fails or prints no report is no verdict and never demotes; the tier probe uses an empty journal. - UNSLOTH_MXC_PIN only skips the probe when it names a real pin. - dacl_fallback_enabled() is off on 1.1.0, so saved consent adds no grants, leases or allowDaclMutation. - A 1.1.0 PC without MXC gets the windows-setup action with only the install step, which Chat and Settings already offer, and remediation that does not point at the fallback sandbox. - A DACL journal that cannot be replayed cleanly keeps the retiring runtime instead of swapping in 1.1.0. - An unreadable UBR still uses the product type and build; the demotion marker is written atomically. [skip ci]
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f5c768760e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Codex Review: Didn't find any major issues. 👍 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
…in container target_pin() is what the installer puts on this PC; selected_pin() is what Studio runs. When the target is 1.1.0 but 1.0.1 is still installed, Studio keeps using 1.0.1 (which also runs in the built-in container) instead of reporting the runtime missing until the next install moves the PC to 1.1.0. [skip ci]
|
Codex Review: Didn't find any major issues. Swish! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
…er strand a DACL journal - A staged 1.1.0 whose probe gives no verdict, or that an elevated installer would have to probe, no longer replaces a working 1.0.1; the next install asks again. - An unreadable journal or retiring runtime, or journal entries a live run left behind, block the swap to 1.1.0, which cannot replay them. - The installer keeps the demotion marker and journal beside --install-dir (setup.ps1 also honours UNSLOTH_HOME), and a marker only demotes the primary pin it was recorded for. - A marker write error is reported like any other install error. [skip ci]
|
@codex review |
1 similar comment
|
@codex review |
|
Codex Review: Didn't find any major issues. 🚀 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
…Windows release and architecture once An elevated installer already runs Python from the same user-writable Studio folder, so refusing the probe protected nothing and kept administrators without UAC on 1.0.1. The release and the native architecture cannot change while a process runs; selected_pin() measured about 300 us per call on Windows 11 ARM64. [skip ci]
|
@codex review |
1 similar comment
|
@codex review |
|
Codex Review: Didn't find any major issues. 🚀 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Studio pins Microsoft MXC 0.8.0. npm's latest is 1.1.0, and on the built-in Windows container 0.9.0 and newer run about 20 ms faster per call: 103 vs 127 ms for a shell command and 110 vs 135 ms for Python on Windows 11 ARM64, measured with bare
wxc-execand Studio's own policy.1.1.0 cannot simply replace 0.8.0. It removed the AppContainer + DACL tier and
wxc-host-prep(microsoft/mxc#1558), so it runs only where Windows has the built-in container (BaseContainer): Windows 11 at build 26100.9278, 26200.9278, 26300.9550, 28000.2804 or newer. On Windows Server 2025 and 2022 it refuses every launch, while--probestill exits 0 and names no tier.This PR pins both:
wxc-host-prep, so those PCs keep today's opt-in fallback sandbox.How the pin is chosen
mxc_runtime.selected_pin():UNSLOTH_MXC_PIN=1.1.0or1.0.1forces a pin.mxc_runtime.BUILTIN_CONTAINER_MIN_UBR.wxc-exec --probebefore it replaces anything. If the probe reports any tier other thanbase-container, or none, the installer installs 1.0.1 instead and only then records that for this exact Windows release (mxc-runtime/pin-demoted.json). A Windows update changes the release, so 1.1.0 is tried again after it. A probe that fails or prints no report is no verdict: it never demotes, and it never replaces a working 1.0.1 with an unproven 1.1.0. A failed 1.0.1 install records nothing, so the next run asks again. The marker and journal live beside--install-dir, so a customUNSLOTH_HOMEkeeps them together.Both pins install into the same
mxc-runtime/windows-<arch>folder.setup.ps1and Desktop are unchanged and still callinstall_mxc_prebuilt.py --install-dir ...on every setup and update. A PC that crosses the floor after a Windows update keeps running its installed 1.0.1, which also uses the built-in container, until the next update or the Settings install button installs 1.1.0.target_pin()is what the installer installs;selected_pin()is what Studio runs, which is the same except for that case.What changes
mxc_runtime.MxcPin,PRIMARY_PIN,LEGACY_PIN): version, release commit, archive size and SHA-256, and per-architecturewxc-exec.exe(pluswxc-host-prep.exefor 1.0.1) member, size and SHA-256. I downloaded each archive from npm, checked it against npm'sdist.integrity, and hashed every member. All of them carry a valid Microsoft Corporation Authenticode signature.mxc_policy.build_launch_request). 1.0 and newer reject0.8.0-alpha. The only change the parser demands is the network section:{"egress": {"default": "allow"}, "ingress": {"default": "allow", "hostLoopback": "deny"}}.denyis also the onlyhostLoopbackvalue the DACL tier accepts.PROFILE_IDmoves to-v3, so cached capability verdicts from the 0.8.0 profile are not reused.probe_host_prep_steps()returns nothing to prepare on 1.1.0.mxc_policy.dacl_fallback_enabled()is always off on 1.1.0, so a choice saved under 0.8.0 or 1.0.1 never adds grants or leases, or asks forallowDaclMutation, there.windows-setupaction Chat and Settings already show), never the consent or the administrator step, and its remediation text no longer points at the fallback sandbox.install_mxc_prebuilt.py):.github/workflows/mxc-pin-network-check.yml): schedule and manual only, never on pull requests, modeled on the model catalog check. It runstest_mxc_pin.pywithUNSLOTH_MXC_PIN_NETWORK=1in a bare Python with pytest only (about 0.5 s) and fails when npm'slatestis not the primary pin.Tests
test_mxc_pin.py(about 0.5 s, offline by default):wxc-host-prep;probe_tierparsing, and a failed or report-less probe raising instead of naming no tier;test_install_mxc_prebuilt.py:wxc-exec.exe;appcontainer-daclor no tier, and stays when it namesbase-container;UNSLOTH_MXC_PINvalue still lets the probe decide;test_sandbox_setup_plan.py: a 1.1.0 PC is offered only the runtime install, installed or not.Staging (real Windows runners)
mxc_pin_e2eruns the branch's own installer into a fresh Studio home, checks the Authenticode signatures, makes real sandboxed tool calls throughtools.execute_toolin required mode, timesselected_pin()per call, and runs the MXC test files on the runner. Head98ee5d10a:--probetierselected_pin()per callmxc-processcontainerwith effective modeos_isolated. The 1.0.1 legs ran the fallback sandbox after--prepare-host.wxc-execcomparison above is the version-to-version number.