Skip to content

v1.0.3 - Quiet Windows scripting optimization fix + Cleanup

Choose a tag to compare

@no6969el no6969el released this 21 Aug 20:06
· 4 commits to main since this release
5689580

Error reporting fixes — the kit can now hear its own failures
This release fixes a class of bug where QuietWindows reported success after doing nothing. No features changed, no new settings, no changes to what gets disabled or restored.
The main bug
Declining the Windows admin prompt raises a non-terminating error, which try/catch ignores by default. All three elevation paths relied on that catch. The result: press No on the UAC prompt, and the one-click runner still printed a green ALL DONE.
All Start-Process -Verb RunAs calls now use -ErrorAction Stop, so a declined prompt is actually detected and reported.
The bigger problem underneath
The individual fix scripts caught their own errors and returned normally on failure — not running as admin, Defender commands unavailable, no supported GPU found, registry write refused. Every one of those looked like success to the caller, so no amount of checking on the orchestrator side could have seen them.
The most common real-world case: running without admin rights, where every step printed a red ERROR and stopped, and the summary still said ALL DONE.
Fix scripts now exit non-zero on genuine failure. Optimize-My-PC waits for the elevated child, reads its exit code, counts failed steps, and reports the count instead of claiming success. "No games added yet" is still treated as a normal skip, not a failure.
Also in this release
wevtutil is a native executable and never threw, so log-enable failures were invisible. Its exit code is now checked.
Unbounded service stop: Stop-Service -Force has no timeout, so a wedged service (WSearch mid-index is the usual one) could park an elevated run with services half-disabled. Replaced with a 20-second bounded stop that walks dependent services first, preserving the previous -Force behaviour. A service that won't stop is now reported rather than hanging the run.
schtasks exit codes on the SYSTEM helper path. A refused task scheduler now reports immediately instead of waiting out the full 30-second poll.
Notes
The one-click window keeps its quiet error preference; it is cosmetic only, and anything that must be heard now sets its own error handling explicitly.
The menu's one-click button remains fire-and-forget by design — waiting on it would freeze the window — so it reports launch failures but not per-step results. Use Optimize-My-PC.bat if you want the full summary.
Restore behaviour, snapshots, and permission handling are untouched.
Upgrading: drop-in replacement. No snapshot format change, no migration. If you have a quiet session active, restoring with the old version and re-applying with the new one is unnecessary but harmless.