Repository navigation
fix(windows): preserve Unicode LAN route aliases - #122263
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
@clawsweeper review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Codex review: needs maintainer review before merge. Reviewed August 11, 2026, 6:01 PM ET / 22:01 UTC. ClawSweeper reviewWhat this changesThe PR makes the Windows PowerShell route probe emit UTF-8 so localized network-adapter aliases continue to match local interfaces when choosing the advertised LAN host. Merge readinessKeep open. Current main still emits the Windows route JSON without an encoding declaration, while this PR corrects that producer boundary and adds native Windows coverage; no blocking patch defect was found. The maintainer label and member authorship require normal maintainer handling rather than automated cleanup. Priority: P2 Review scores
Verification
How this fits togetherOpenClaw resolves a LAN address from local network interfaces and, on Windows, uses the default route reported by PowerShell to pick the preferred address. That selected address feeds pairing, gateway system information, and LAN links. flowchart LR
A[Local network interfaces] --> C[LAN host resolver]
B[Windows route probe] --> C
C --> D[Route alias match]
D --> E[Selected LAN address]
E --> F[Pairing and gateway links]
Decision needed
Why: The PR carries the protected maintainer label and is authored by a repository member, so automated cleanup must pause for an explicit maintainer choice despite the clean review. Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource -1, Tests +89, Config 0, Other 0. Total +88 across 7 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Technical reviewBest possible solution: Merge the producer-side UTF-8 correction with its native PowerShell regression and existing Windows CI routing retained. Do we have a high-confidence way to reproduce the issue? Yes for a high-confidence source path: on Windows, serialize a Unicode route alias after selecting a legacy console encoding, then resolve the advertised host. The PR supplies that native child-process scenario, although this read-only reviewer environment could not rerun PowerShell locally. Is this the best way to solve the issue? Yes. Encoding the bytes at the PowerShell producer matches the existing UTF-8-first decoder and avoids a downstream fallback or caller-specific workaround. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 459c70e14a2c. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
* origin/main: (1725 commits) fix(agents): preserve reply cleanup when cancellation throws (#122252) fix(ui): render disallowed link schemes as plain text (#122311) fix(test): isolate gateway helper env stubs (#122319) fix(ui): keep chat Markdown block rhythm consistent (#122289) test(cli): trim duplicate Hooks process cases (#122278) fix(ui): retain identity while agent roster loads fix(ui): preserve configured agent labels fix(plugins): keep startup convergence read-only (#122330) fix: preserve WebChat reply context after reloads (#122169) fix(ui): make DONE moves visibly reversible (#122303) fix(ui): keep inline-code punctuation attached (#122291) fix(google-meet): publish exports atomically (#122306) fix(channels): preserve failed agent run reactions (#122009) fix(ui): label patch file operations accurately (#122287) fix(windows): preserve Unicode LAN route aliases (#122263) test(media): synchronize transcode pool completion (#122279) fix(android): keep completed subagent activity visible for sixty seconds (#122089) fix(ui): humanize bare GitHub item links (#122285) refactor(qqbot): install plugin from Tencent package (#107295) chore: scope SQLite session lifecycle CI (#121917) ...
Summary
resolveAdvertisedLanHostCoreowner and remove unused route JSON fieldsRoot cause and fix
Get-NetRoute | ConvertTo-Jsoninherited the host console output code page. On localized Windows systems, an adapter alias such asréseau-网卡could therefore be emitted in a legacy code page while OpenClaw decoded the child output as UTF-8, so the route alias no longer matchedos.networkInterfaces()and LAN advertisement could select the wrong fallback address.The route producer now sets
[Console]::OutputEncodingtoUTF8Encoding(false)beforeGet-NetRoute. This is the owner boundary where the bytes are created; callers in pairing, gatewaysystem.info, Control UI links, and device-pair keep consuming the same resolved host. Microsoft documents thatConsole.OutputEncodingcontrols console output bytes and that the default code page is locale-dependent: https://learn.microsoft.com/en-us/dotnet/api/system.console.outputencoding and https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_character_encodingNo config, protocol, storage, or public API surface changes.
Verification
réseau-网卡git diff --check, changed-lane classification, and plugin SDK surface gate cleanChange size
Fresh publication guard used main
c2ad148cb8b750587217b249d0ade95fcb534bdd: candidate paths had zero drift, the patch was unsuperseded, and merge-tree was clean.