Repository navigation
v1.0.30
Fixes the Dismount-WindowsImage -Save lock that broke ISO creation — at its real root cause. v1.0.29 (now retracted) misdiagnosed the WIM-commit failure as transient host interference and bolted on a retry; the lock is actually an in-process .NET registry-provider handle held by the build's own PowerShell process, which a retry can never clear. Offline-hive value enumeration now uses reg.exe exclusively (never the HKLM:\z* provider), so no hive handle is held at dismount time — the reg.exe-only pattern of upstream tiny11builder and Microsoft's offline-servicing docs. Pester 521/0 (plus the admin-gated Synthetic harness).
Fixed
- The Standard build no longer fails at
Dismount-WindowsImage -Savewith "The process cannot access the file because it is being used by another process." Root cause:Invoke-RegistryPatternZeroActionread the loaded offlineNTUSERhive through the .NET PowerShell registry provider (Test-Path/Get-ItemonHKLM:\z…). The provider caches an in-processRegistryKeyhandle to the hive's backing file inside the mount; the kernel keeps a hive loaded while any key handle is open, andreg unloadhas no force flag — so the handle survived into the dismount and lockedinstall.wim. v1.0.29's retry could not help: the handle is held by the same long-lived process for the whole retry window, and GC (the only thing that would release it) is non-deterministic and never fires during the backoff. The latent bug has existed since v1.0.3 — the provider read predates the v1.0.28 idiom tweak and was byte-identical in the v1.0.27 "revert to v1.0.6" — surfacing intermittently with GC timing and deterministically once a build actually reached the commit step. This corrects the v1.0.26–v1.0.29 "a transient WIM dismount/save file-lock is the leading suspect" framing: it was never environmental. - Stale-hive recovery (
Clear-Tiny11StaleHives) no longer opens a provider handle either. It detected strandedHKLM\z*hives withTest-Path HKLM:\z…, which — on the exact stranded-hive path it exists to recover — opened a fresh in-process handle. It now probes viareg.exe(Test-Tiny11HiveLoaded).
Changed
- All offline-hive registry access in the build process is now
reg.exe-only. NewTiny11.Hiveshelpers:Get-Tiny11RegValueNames(value-name enumeration viareg query, replacingGet-Item … | Select-Object -ExpandProperty Property),Test-Tiny11HiveLoaded(load check viareg query), andInvoke-Tiny11RegExe(a%SystemRoot%\System32\reg.exeabsolute-path wrapper — child process, handle closed on exit).Invoke-RegistryPatternZeroActionis rewritten ontoGet-Tiny11RegValueNames. No change to a successful build's output image — the same value names are matched and the samereg add … /d 0writes are issued. - v1.0.29's WIM-integrity gate and
-Saveretry are retained as defense-in-depth (harmless, and they still guard a genuinely bad save or rare external interference), but they are no longer the mechanism — the reg.exe fix removes the in-process cause at the source. - Offline-servicing binaries now resolve from
%SystemRoot%\System32by absolute path, not via%PATH%(Local-Dependencies-Only).reg.exe(HivesInvoke-RegCommand+ Core's inline tweak writes),dism.exe(Worker cleanup/export, Core appx enumeration/removal,Actions.ProvisionedAppx, and theStart-CoreProcesswrapper that backs dism/takeown/icacls), androbocopy.exe(Worker ISO copy) are all OS-intrinsic servicing tools that can't be vendored, so they're pinned to the System32 path — blocking a PATH-hijacked stand-in. NewTiny11.HivesresolversGet-Tiny11RegExePath/Get-Tiny11DismExePath. (The post-boot cleanup script'sreg.exeruns on the target machine — a separate context — and is unchanged.)
Added
- Regression guard
tests/Tiny11.OfflineHive.NoProvider.Drift.Tests.ps1— a static scan that fails if anysrcmodule reintroduces anHK*:\zoffline-hive provider-drive reference. Plus reg.exe-only unit coverage forGet-Tiny11RegValueNames,Test-Tiny11HiveLoaded, and the rewrittenInvoke-RegistryPatternZeroAction. (The v1.0.29 synthetic-WIM harness never loaded a registry hive, so it structurally could not have caught this class.)
Notes
- Process fix: v1.0.29 shipped without a real end-to-end ISO build — only the content-agnostic synthetic-WIM test ran in CI — which is exactly why a real-build regression slipped through. v1.0.30 is gated on an actual
install.wim-loading build (load hives → pattern-zero → unload → dismount-save) before release. - v1.0.29 was retracted: its GitHub release and Velopack feed assets were deleted, so v1.0.28 remains the offered latest until v1.0.30 ships. The signed
v1.0.29tag is retained — the repo's tag-protection ruleset blocks tag deletion.