Test suites leak mosaic-business-* and mosaic-launch-* directories in TMPDIR #1624

Open
opened 2026-10-14 18:46:38 +00:00 by jarvis · 0 comments
Contributor

Darkwing flagged it in the row 116 round 1 handoff: each full gate leaves about 345 mosaic-business-* and mosaic-launch-* directories in TMPDIR.

Counted on 2026-10-14 in the shared /mnt/storage/scratch/tmp: 11197 mosaic-business-* and 175 mosaic-launch-*.

  • packages/business/tests/helpers.mjs:13: tmp() calls mkdtempSync and nothing removes the directory. Every business test that uses it leaks one.
  • packages/cli/tests/helpers.mjs:14: tmp(t, prefix) registers t.after(rmSync(..., force)), but some mosaic-launch-* roots (from launcher.test.mjs:65) survive. The likely causes are files the sandboxed launch leaves unremovable, or a cleanup that runs before a child exits. Not yet confirmed.

Wanted: the business tmp() takes t and removes its directory in t.after, as the cli helper does. Find why the launch roots survive and fix that. Then a full gate leaves no new mosaic-* directories in TMPDIR, checked by counting before and after.

Not urgent, and it is not row 116's. Nobody deletes the existing leftovers until this lands, because gates share that TMPDIR.

Darkwing flagged it in the row 116 round 1 handoff: each full gate leaves about 345 `mosaic-business-*` and `mosaic-launch-*` directories in TMPDIR. Counted on 2026-10-14 in the shared `/mnt/storage/scratch/tmp`: 11197 `mosaic-business-*` and 175 `mosaic-launch-*`. - `packages/business/tests/helpers.mjs:13`: `tmp()` calls `mkdtempSync` and nothing removes the directory. Every business test that uses it leaks one. - `packages/cli/tests/helpers.mjs:14`: `tmp(t, prefix)` registers `t.after(rmSync(..., force))`, but some `mosaic-launch-*` roots (from `launcher.test.mjs:65`) survive. The likely causes are files the sandboxed launch leaves unremovable, or a cleanup that runs before a child exits. Not yet confirmed. Wanted: the business `tmp()` takes `t` and removes its directory in `t.after`, as the cli helper does. Find why the launch roots survive and fix that. Then a full gate leaves no new `mosaic-*` directories in TMPDIR, checked by counting before and after. Not urgent, and it is not row 116's. Nobody deletes the existing leftovers until this lands, because gates share that TMPDIR.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: mosaicstack/stack#1624