Skip to content

fix(test): read the packed tarball from its folder on Windows - #161

Merged
Upd4ting merged 1 commit into
mainfrom
test/wec9b4589-24-pack-windows
Nov 20, 2026
Merged

Upd4ting merged 1 commit into
mainfrom
test/wec9b4589-24-pack-windows

Conversation

@Upd4ting

@Upd4ting Upd4ting commented Nov 20, 2026 •

Copy link
Copy Markdown
Member

Summary

Wec9b4589-24. The nightly ci / Node .nvmrc on Windows (run 44660718684) fails in tests/package.test.mjs: readPacked returned empty text, so JSON.parse threw "Unexpected end of JSON input" and the four tarball tests were cancelled. The pack itself works (npm pack already runs with a shell on win32). The cause is tar from Git for Windows (GNU tar) reading the absolute D:\... tarball path as host:path, so it extracted nothing and the test ignored the exit status.

The helper now runs tar with cwd set to the pack folder and the bare tarball name, asserts each tar exits 0, and splits output on \r?\n.

Related issue

ANT-3515 (nightly failure).

Verification

  • Before: Windows nightly run 44660718684, SyntaxError: Unexpected end of JSON input at pack (tests/package.test.mjs:60).
  • Locally on Linux (without dist built): node --test tests/package.test.mjs runs 3 of 4 tests as before; the fourth fails only because dist is not built here.
  • After: a manual run cannot reach the nightly tier (the shared ci-tier action returns nightly only for schedule), so the proof is the next 02:17 UTC scheduled nightly. The manual run on this branch (https://github.com/AntelopeJS/dms-lang/actions/runs/44825996953) passed its Linux Node and Extra legs.
flowchart LR
  A[npm pack in repo] --> B[tarball name in folder]
  B --> C[tar with cwd=folder, relative name]
  C --> D[exit 0 asserted, JSON parsed]
Loading

Follow-ups

  • none

Checklist

  • The pull request title follows Conventional Commits.
  • I added or updated tests when behavior changed.
  • I updated documentation when users or contributors are affected.
  • I documented breaking changes and migration steps.
  • I did not include credentials or unrelated changes.

@Upd4ting
Upd4ting marked this pull request as ready for review November 20, 2026 22:16
@Upd4ting
Upd4ting added this pull request to the merge queue Nov 20, 2026
Merged via the queue into main with commit 35f456d Nov 20, 2026
29 checks passed
@Upd4ting
Upd4ting deleted the test/wec9b4589-24-pack-windows branch November 20, 2026 22:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant