Skip to main content
← Back to list
01Issue
BugShippedSwamp CLIPublic
Assigneesstack72

Relationships

#2157 Windows: CLI resolves 8.3 short names to long names, breaking path comparisons

Opened by stack72 · 9/15/2026· Shipped 9/15/2026

Description

On Windows, Deno.makeTempDir() returns paths using 8.3 short filenames (e.g. C:\Users\[REDACTED]\AppData\Local\Temp\...). When these paths are passed to swamp CLI commands like extension source add, the CLI internally resolves them to their long-name equivalents (e.g. C:\Users\[REDACTED]\AppData\Local\Temp\...).

This means the path returned by the CLI in JSON output no longer matches the path that was passed in, breaking any comparison between the input path and the CLI-reported path.

Steps to Reproduce

  1. On Windows, create a temp directory (returns 8.3 short name)
  2. Run swamp extension source add <temp-dir>
  3. Query swamp doctor extensions --verbose --json
  4. The sourcePath in the output uses the long name, not the short name that was passed in

Example:

  • Input: C:\Users\[REDACTED]\AppData\Local\Temp\abc123
  • CLI output: C:\Users\[REDACTED]\AppData\Local\Temp\abc123\extensions\models\test\hello.ts
  • includes("RUNNER~1") → false

Environment

  • Windows Server 2022 (GitHub Actions windows-latest)
  • swamp version: 20260915.001037.0-sha.c42457d4
  • Discovered via Windows UAT runner (swamp-uat#363)

Impact

7 UAT test failures: extension source add (4 kinds + doctor detail), extension source rm (2 kinds).

Suggested Fix

Either preserve the path as given (don't canonicalize), or canonicalize consistently at input time so both the stored path and the returned path match. The former is simpler — Deno.realPathSync() is what likely causes the expansion, and skipping it would preserve the caller's path form.

02Bog Flow
OPENTRIAGEDIN PROGRESSSHIPPED+ 1 MOREASSIGNED+ 4 MOREREVIEW+ 7 MOREPR_MERGED+ 2 MORESESSION_SUMMARIZED

Shipped

9/15/2026, 7:08:24 PM

Click a lifecycle step above to view its details.

03Sludge Pulse
stack72 assigned stack729/15/2026, 6:38:11 PM

Sign in to post a ripple.