singularity-forge/packages
Tom Boucher 4cb6252b9b fix(perf): share jiti module cache across extension loads (#3308)
* fix(perf): share jiti module cache across extension loads (#2108)

Each extension was creating a new jiti instance with moduleCache: false,
causing shared dependencies to be recompiled for every extension. Use a
shared singleton with moduleCache: true so shared modules are compiled once.

Export resetExtensionLoaderCache() for test teardown and explicit reload.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix: correct loader path in extension-load-perf test (4 → 3 levels up)

The test file is at src/tests/ (2 levels deep from repo root), so
fileURLToPath(import.meta.url) + 3x'..' reaches the repo root.
Using 4 levels exits the repo into the GitHub Actions workspace parent,
causing ERR_MODULE_NOT_FOUND for loader.js in dist/.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix: use process.cwd() for loader path in perf test (source/compiled portability)

import.meta.url resolves to different depths in source (src/tests/) vs compiled
(dist-test/src/tests/), so relative '../' navigation produces the wrong path in
the build phase. process.cwd() is always the repo root in CI regardless of
where the test file is compiled to.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

---------

Co-authored-by: trek-e <trek-e@users.noreply.github.com>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-05 07:59:17 -04:00
..
daemon wip: M005 daemon — orchestrator, event bridge, formatter, batcher improvements (#2929) 2026-03-27 20:22:30 -06:00
mcp-server feat(mcp-server): add 6 read-only tools for project state queries (#3515) 2026-04-04 16:41:24 -05:00
native fix: align @gsd/native module type with compiled output (#3253) 2026-03-30 13:51:57 -06:00
pi-agent-core fix: cap consecutive tool validation failures to prevent stuck-loop (#3301) 2026-04-05 01:04:58 -04:00
pi-ai fix(pi-ai): extend repairToolJson to handle XML tags and truncated numbers 2026-04-04 03:59:55 -07:00
pi-coding-agent fix(perf): share jiti module cache across extension loads (#3308) 2026-04-05 07:59:17 -04:00
pi-tui fix: skip TUI render loop on non-TTY stdout to prevent CPU burn (#3095) (#3263) 2026-03-30 13:49:55 -06:00
rpc-client feat: Headless Integration Hardening & Release (M002) (#2811) 2026-03-26 23:33:22 -06:00