Skip to content

Fix Windows PowerShell packaging test parser - #1134

Merged
shanselman merged 1 commit into
mainfrom
shanselman-fix-packaging-parser
Aug 8, 2026
Merged

shanselman merged 1 commit into
mainfrom
shanselman-fix-packaging-parser

Conversation

@shanselman

Copy link
Copy Markdown
Collaborator

Summary

  • replace encoding-sensitive Unicode punctuation and box-drawing characters in Test-InnoUninstallOrdering.ps1 with ASCII equivalents
  • preserve all packaging and uninstall-ordering test behavior
  • allow UTF-8-without-BOM source to parse reliably in Windows PowerShell 5.1

Validation

  • git diff --check (passed)
  • ./build.ps1 (passed)
  • dotnet test ./tests/OpenClaw.Shared.Tests/OpenClaw.Shared.Tests.csproj --no-restore (passed: 3,631; skipped: 32)
  • dotnet test ./tests/OpenClaw.Tray.Tests/OpenClaw.Tray.Tests.csproj --no-restore (passed: 2,246)
  • powershell.exe -NoLogo -NoProfile -ExecutionPolicy Bypass -File ./tests/PackagingTests/Test-InnoUninstallOrdering.ps1 -OutputDir <temp> (reached legitimate no-installer SKIP, exit 2; no parser error)
  • pwsh -NoLogo -NoProfile -File ./tests/PackagingTests/Test-InnoUninstallOrdering.ps1 -OutputDir <temp> (reached legitimate no-installer SKIP, exit 2)
  • ASCII scan with Select-String -Pattern '[^\x00-\x7F]' (no matches)
  • autoreview: clean, no accepted/actionable findings
  • rubber-duck review: clean, no actionable findings

Real behavior proof

Before this change, Windows PowerShell 5.1 exited at parse time around the Markdown table near line 194. At this PR head, both powershell.exe 5.1 and pwsh execute the script through installer discovery and return the expected SKIP verdict because no installer is present on the validation host.

Replace encoding-sensitive Unicode punctuation and box drawing in the Inno uninstall ordering test with ASCII equivalents so Windows PowerShell 5.1 parses the UTF-8-without-BOM script reliably.

Co-authored-by: Copilot App <[email protected]>
@shanselman shanselman added the status: 🚢 actively landing A maintainer or agent is actively driving this item through implementation, validation, or merge. label Aug 8, 2026
@clawsweeper clawsweeper Bot added rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. P3 Low-risk cleanup, docs, polish, ergonomics, or speculative feature. labels Aug 8, 2026
@clawsweeper

clawsweeper Bot commented Aug 8, 2026

Copy link
Copy Markdown

Codex review: needs maintainer review before merge. Reviewed August 8, 2026, 4:20 PM ET / 20:20 UTC.

ClawSweeper review

What this changes

The PR replaces non-ASCII punctuation and box-drawing text in the Inno Setup uninstall-ordering PowerShell test so Windows PowerShell 5.1 can parse its UTF-8-without-BOM source reliably.

Merge readiness

✅ Ready for maintainer review

Keep open. This collaborator-owned active PR is a focused compatibility repair, and source review found no actionable defect.

Priority: P3
Reviewed head: be2b4e60514336d61f6a56ad2400c31b9b80da3e

Review scores

Measure Result What it means
Overall readiness 🦞 diamond lobster (5/6) The narrow parser fix preserves the packaging-test behavior and has direct current-head execution evidence in the PR body.
Proof confidence 🌊 off-meta tidepool Not applicable: This collaborator PR includes a current-head Windows PowerShell 5.1 and pwsh execution result; external-contributor proof gating does not apply.
Patch quality 🦞 diamond lobster (5/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This collaborator PR includes a current-head Windows PowerShell 5.1 and pwsh execution result; external-contributor proof gating does not apply.
Evidence reviewed 6 items Current-main parser-sensitive source: The current-main test contains non-ASCII punctuation in its source text, including an em dash in the synopsis.
Narrow behavior-preserving diff: All 23 replacements are comments or presentation and diagnostic literals; installer discovery, uninstall invocation, and ordering comparison logic are unchanged.
ASCII verification: The PR-head version of the script has no non-ASCII source characters.
Findings None None.
Security None None.

How this fits together

The packaging test locates a built Windows installer, runs its uninstall path, and checks that the gateway cleanup hook precedes deletion of the application directory. Its console and JSON verdicts feed local and CI packaging validation.

flowchart LR
  A[Built Windows installer] --> B[Packaging test script]
  B --> C[PowerShell parser]
  C --> D[Installer discovery]
  D --> E[Uninstall ordering check]
  E --> F[Console and JSON verdict]
Loading

Before merge

None.

Agent review details

Security

None.

Review metrics

Metric Value Why it matters
Patch scope 1 file, 23 additions, 23 deletions Every changed line is presentation text or a comment in the packaging test.

Technical review

Best possible solution:

Land the ASCII-only presentation-text change after normal CI completes, retaining the existing uninstall-ordering test contract.

Do we have a high-confidence way to reproduce the issue?

Yes. Current main has non-ASCII source literals, while the PR removes them without changing the installer or ordering path; the Windows PowerShell 5.1 parser issue is source-reproducible.

Is this the best way to solve the issue?

Yes. ASCII substitutions in presentation-only literals are the narrowest maintainable remedy for Windows PowerShell 5.1 source decoding.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against b5925f0cc3f8.

Labels

Label changes:

  • add P3: This is a low-risk parser-compatibility repair in a test script.
  • add rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🌊 off-meta tidepool and patch quality is 🦞 diamond lobster.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This collaborator PR includes a current-head Windows PowerShell 5.1 and pwsh execution result; external-contributor proof gating does not apply.

Label justifications:

  • P3: This is a low-risk parser-compatibility repair in a test script.
  • rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🌊 off-meta tidepool and patch quality is 🦞 diamond lobster.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This collaborator PR includes a current-head Windows PowerShell 5.1 and pwsh execution result; external-contributor proof gating does not apply.

Evidence

What I checked:

Likely related people:

  • Scott Hanselman: Current-file blame attributes the parser-sensitive text to the recent history boundary commit. (role: recent area contributor; confidence: high; commits: ddad64031116; files: tests/PackagingTests/Test-InnoUninstallOrdering.ps1)
  • Mike Harsh: History associates the test's introduction with the WSL gateway uninstall feature. (role: feature introducer; confidence: high; commits: 223db1fb847e; files: tests/PackagingTests/Test-InnoUninstallOrdering.ps1)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@shanselman
shanselman merged commit 50a9455 into main Aug 8, 2026
25 checks passed
@shanselman shanselman removed the status: 🚢 actively landing A maintainer or agent is actively driving this item through implementation, validation, or merge. label Aug 8, 2026
@shanselman
shanselman deleted the shanselman-fix-packaging-parser branch August 8, 2026 20:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P3 Low-risk cleanup, docs, polish, ergonomics, or speculative feature. rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant