-
Notifications
You must be signed in to change notification settings - Fork 0
Update and Uninstall
github-actions[bot] edited this page May 6, 2026
·
5 revisions
Both flows ship as standalone single-file exes that live next to WKVRCProxy.exe.
Sources:
-
src/WKVRCProxy.Updater/Program.cs--WKVRCProxy.Updater.exe -
src/WKVRCProxy.Uninstaller/Program.cs--WKVRCProxy.Uninstaller.exe -
.github/workflows/release.yml-- produces the zip the updater consumes
No flags. Running it is the request to check-and-maybe-update. Behaviour:
- Sweeps stale
%TEMP%\WKVRCProxy-extract-*andWKVRCProxy-*.zipartifacts older than 1 day from prior failed runs. - Reads the watchdog's
FileVersionInfoto determine "current version". - GETs
https://api.github.com/repos/RealWhyKnot/WKVRCProxy/releases/latestwith a 30-second timeout,UseDefaultCredentials=truefor corp NTLM proxies, and aContent-Type: *json*check (Cloudflare's "Always Online" returns 200+HTML; we surface a clearer error in that case). - Parses the tag, strips the leading
vand any-XXXXdev suffix, parses asSystem.Version. - If the remote isn't newer, prints
You're on the latest version.and exits. - Otherwise prompts:
Update available -- install now? [Y/N] (auto-N in 15s). Times out as No if the user is AFK. - On Yes:
- Downloads the
.zipasset with a 10-minute hard cap and a pre-download free-disk-space probe (refuses if temp drive has <1.5x the asset size free). - Verifies SHA256 against the release body's
^SHA256: <hex>$line (anchored to start-of-line, multiline, so a sample placeholder elsewhere in the body can't false-match). - Extracts to a temp dir.
- Only now does the updater stop the running watchdog -- pre-stop failures leave the running install untouched.
- Stops the watchdog gracefully via
AttachConsole+GenerateConsoleCtrlEvent(CTRL_C)so the watchdog runs its real shutdown (atomic restore + clean_exit.flag) before exit. Falls back toKillafter 5 s. - Polls "no
WKVRCProxy.exeprocess ANDGlobal\WKVRCProxy.Watchdogmutex acquirable" with a 5-second budget so the new watchdog launched at the end ofMain()doesn't race the kernel's mutex-handle release. - Atomic two-pass copy: stages every file as
<dst>.new-<short>, then rename pass with up to 3 retries + 200 ms backoff per file (absorbs brief AV-scanner holds). On midway failure, restores from.old-<short>sidecars; surfaces rollback failures in the rethrown exception with a manual-recovery hint listing each unrecovered file. - Lock-error messages are decorated for known critical files: a locked
yt-dlp.exesays "close VRChat (it may be holding yt-dlp.exe)"; a lockedWKVRCProxy.exesays "watchdog process may not have fully exited yet". - Relaunches the watchdog and exits.
- Downloads the
Per-step Logger.WriteFileOnly breadcrumbs go to %LOCALAPPDATA%Low\WKVRCProxy\logs\updater-<utc>.log. A future "updater failed" report has the URL fetched, response status, asset chosen, SHA expected/actual, file count, and rollback details.
No flags. No prompt. Running it IS consent. Five steps:
-
close-watchdog-- closes onlyWKVRCProxy.exeprocesses whoseMainModule.FileNamematches THIS install's exe (so a parallel install's watchdog isn't killed when uninstalling this one). SendsCloseMainWindow, falls back toKillafter 5 s. -
restore-yt-dlp-- atomic move ofyt-dlp-og.exe->yt-dlp.exein VRChat's Tools dir. Locked-target fallback: rename current to.stale-<utc>then move backup over. Belt-and-suspenders: if backup went missing, drops the bundledtools/yt-dlp-og-fallback.exein. Loud warning if both backup AND bundled fallback are missing AND VRChat'syt-dlp.exeexists -- without intervention, VRChat would be left with our patched wrapper pointing at a soon-to-be-deleted install dir; user's told to deleteTools/yt-dlp.exemanually so VRChat re-downloads on next launch. -
remove-hosts-- re-execsWKVRCProxy.exe --remove-hosts-entryunderrunasto remove the127.0.0.1 localhost.youtube.comline. Pre-checks the hosts file first; if no entry is present, skips the UAC prompt entirely (users who never enabled public-instance mode don't see a UAC dialog for a no-op write). -
wipe-state-- releases the open log writer (Logger.Close()) so subsequentDirectory.Deletedoesn't hit a sharing violation, then wipes BOTH%LOCALAPPDATA%Low\WKVRCProxy\(current state root) AND the legacy%LOCALAPPDATA%\WKVRCProxy\tree (in case migration was incomplete). -
schedule-self-delete-- detachedcmd.exe /c (ping -n 4) & rmdir /s /q "<install>"with output redirected to%TEMP%\WKVRCProxy-uninstall-rmdir-<utc>.logso a stuck rmdir leaves a diagnostic trail. The 3-second delay covers AV scanners briefly holding the uninstaller's own exe handle.
Each step emits [uninstall] <step> start / ok / ERROR breadcrumbs to %LOCALAPPDATA%Low\WKVRCProxy\logs\uninstaller-<utc>.log so a "uninstall left X behind" report can identify which step failed.
-
Hardcoded GitHub URL: the updater hits
api.github.com/repos/RealWhyKnot/WKVRCProxy. If the repo moves, all installs need a manual update. -
Protected install location: installing under
Program Filesmeans the deferredcmd.exe rmdirruns without elevation and may silently fail to remove the directory. The rmdir output log at%TEMP%\WKVRCProxy-uninstall-rmdir-<utc>.logwill show the access-denied error. Document install-anywhere usage; the README does. - UAC declined on uninstall: the hosts entry stays. The uninstaller prints a hint pointing to the manual fix; the leftover line is idle and harmless without WKVRCProxy running.
- Network down during update: the updater never touches the running watchdog if the download/SHA/extract fail. You'll see the error message and your existing install keeps running.
Start here
For users
Reference
For maintainers