Skip to content

fix(update-local): Node installs on German Windows; the double-click asks, then updates - #237

Merged
Nawid3333 merged 2 commits into
mainfrom
claude/update-local-node-acl
Oct 3, 2026
Merged

Nawid3333 merged 2 commits into
mainfrom
claude/update-local-node-acl

Conversation

@Nawid3333

@Nawid3333 Nawid3333 commented Oct 2, 2026 •

Copy link
Copy Markdown
Owner

Updating your PC with update-local turned up three problems in the script. This fixes all three. Nothing here ships, so merging it makes no release.

1. The Node.js update never worked on your PC. It failed twice over:

  • Windows PowerShell 5.1, which update-local.cmd uses, can't run one of its lines (a [void] cast piped on). That was the "Der Argumenttyp kann nicht System.Void sein" error.
  • Past that line, the download folder's permissions named the groups "Administrators" and "SYSTEM" in English. German Windows calls them otherwise ("Administratoren"), so it stopped with "identity references could not be translated".

That part now lives in tools/update-local-lib.ps1 and uses the groups' fixed IDs, which are the same in every language. A Windows test runs it in PowerShell 5.1 and checks that only you, Administrators and SYSTEM have access. Both old versions make that test fail. With the fix, Node 26.7 → 26.10 installed on your PC.

2. Double-clicking update-local.cmd updated nothing. It only reported what was out of date. Now, when something is out of date, it asks "Update these now? [Y,N]", and Y updates everything it listed. When everything is current it doesn't ask. A Windows test drives the .cmd with a stand-in script: nothing to do, a failed step, N, Y. The old .cmd fails the N and Y cases.

3. The check never came back clean. It offered pnpm install and fsaunpack's npm ci every time. Now it offers each one only when its lockfile changed after the last install. A test covers this, and on your PC the check is now fully clean.

Checks: lint, typecheck, and 973 unit tests pass. The new Windows tests run in CI's Windows job. The check exits with 0 on your up-to-date PC and with 2 after the lockfile was made to look changed.

4. Three more fixes in the same script, from the code-review issues:

Fixes #167
Fixes #243
Fixes #244

🤖 Generated with Claude Code

Nawid3333 and others added 2 commits October 3, 2026 00:45
…asks, then updates

- The Node.js step never ran on the owner's PC. Windows PowerShell 5.1 failed on a
  piped [void] cast ("The argument type cannot be System.Void"), and past that the
  staging folder's ACL named 'Administrators' and 'SYSTEM', which a German Windows
  calls otherwise ("identity references could not be translated"). New-PrivateDirectory
  (tools/update-local-lib.ps1) grants by SID; a Windows test runs it in PowerShell 5.1
  and checks the ACL. Both old forms turn it red. Node 26.7 -> 26.10 installed with it.
- update-local.cmd only reported, so a double-click updated nothing. The check now exits
  2 when something is due, and the .cmd asks "Update these now?": Y runs -Apply.
  Tested with a stand-in script: 0, 1, 2+N, 2+Y.
- pnpm install and fsaunpack's npm ci were offered on every check, so it never came
  back clean. Now only when the lockfile changed after the last install
  (Test-ChangedSince against the install markers).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…on, no installer left behind

- #167: getJson's host guard never refused anything: `origin + pathname.startsWith(base)`
  concatenated a boolean, so every URL passed. isPinnedUrl now allows only nodejs.org's
  index.json and package documents on registry.npmjs.org; nine URL cases, six of which
  the old expression lets through.
- #243: the Node version from nodejs.org's index becomes a URL and a file name. newestNode
  takes only the exact "v1.2.3" shape, and update-local.ps1 throws on anything else.
  An index naming "v26.11.0&calc" returned it before; now that entry is skipped.
- #244: a thrown check, a declined admin prompt or a failed install left the ~30 MB
  installer in %ProgramData%. Invoke-InPrivateDirectory removes the folder in a finally;
  a Windows test shows it gone after a throw (it stayed without the finally).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Nawid3333
Nawid3333 merged commit 548e23e into main Oct 3, 2026
9 of 10 checks passed
@Nawid3333
Nawid3333 deleted the claude/update-local-node-acl branch October 3, 2026 20:26
Nawid3333 pushed a commit that referenced this pull request Oct 3, 2026
Brings in the other code-review PRs (#237, #300, #302-#313). Conflicts:
- tools/sync-vendor.mjs: main's unappliedPatches check (#176) moves into
  this branch's main(), so importing the module for its tests runs nothing.
- types/messages.d.ts: this branch's `isExt: true`, main's parentFrameId doc.
- options/index.html: main's sectioned layout, with this branch's
  translated "Learn more" link and without the upstream feedback form.
- docs/vendored-libraries.md: main's knob ref and vtt.js change list, this
  branch's googlevideo row removed and pointer to CHANGES in verify-vtt.mjs.
- native-host/README.md: install.ps1 is about 130 lines now.
- CLAUDE.md: main's sync-upstream paragraph (#163), which already says the
  PR waits for the owner.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JzfFWJzzaUDto87UaqoJGy
Nawid3333 pushed a commit that referenced this pull request Oct 3, 2026
Brings in the other code-review PRs (#237, #300, #302-#313). Conflicts, each
kept from both sides:
- storage.e2e.mjs: main's per-identifier loop, plus this branch's usedOPFS check.
- subtitle-search.e2e.mjs: main's OpenSubtitles DOWNLOAD_LINK, plus this
  branch's wait timeouts.
- TabTracker.test.mjs: main's and this branch's new describe blocks.
- MpvNativeHost.test.mjs: main's imports (a superset).
- MpvNativeHostReadMessage.property.test.mjs: main's version of the
  over-size test, which matches #303's host (an over-size length now waits
  for the body and answers TooLarge, null only when the input ends).

And one test that merged cleanly but no longer held: mpvHostSecurity's
"refuses a message one byte over the limit" now expects TooLarge, the
answer #303 gives once the message has been read.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JzfFWJzzaUDto87UaqoJGy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant