fix(engine): make heartbeat helper imports static to fail fast on partial dist
Convert the dynamic await import("./agent-session-helpers.js") and
await import("./session-skill-context.js") calls inside the heartbeat
executor to static top-level imports, matching the rationale of
26a14698c (which already made the sibling pi.js import static).
This surfaces ERR_MODULE_NOT_FOUND at engine load time rather than
mid-heartbeat when a worktree is on a branch missing the helpers.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
9
.changeset/heartbeat-static-helper-imports.md
Normal file
9
.changeset/heartbeat-static-helper-imports.md
Normal file
@@ -0,0 +1,9 @@
|
||||
---
|
||||
"@runfusion/fusion": patch
|
||||
---
|
||||
|
||||
Convert the heartbeat executor's dynamic `import("./agent-session-helpers.js")`
|
||||
and `import("./session-skill-context.js")` calls to static imports. This makes
|
||||
missing or partial engine dist surface at module load time (matching the
|
||||
existing static `pi.js` import) instead of failing mid-heartbeat with a
|
||||
confusing `ERR_MODULE_NOT_FOUND`.
|
||||
Reference in New Issue
Block a user