Commit Graph

2483 Commits

Author SHA1 Message Date
gsxdsm
4151a19e84 feat: bump pi coding agent to 0.79.1 for Claude Fable 5 support
Update @earendil-works/pi-coding-agent and @earendil-works/pi-ai from
^0.78.0 to ^0.79.1 across cli, engine, and dashboard. This brings in
Claude Fable 5 (claude-fable-5) on the Anthropic and Amazon Bedrock
providers.

Fusion's model picker is registry-driven (/api/models -> pi ModelRegistry,
filtered by provider, not model id), so Fable surfaces automatically for
users with Anthropic or Claude CLI auth configured — no Fusion-side model
list change needed.

Verified: all core packages typecheck clean against 0.79.1; boot smoke
(fn --help, /api/health 200, clean shutdown) passes.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-10 18:51:36 -07:00
gsxdsm
f0d6d70a32 chore(release): v0.40.1
Version bump via changesets.
2026-06-10 18:08:04 -07:00
gsxdsm
9f38b0d090 chore(release): v0.40.0
Version bump via changesets.
2026-06-10 17:58:39 -07:00
gsxdsm
d75f861f24 FN-6199: harden AI merge worktree cleanup
Guarantee AI merge clean-room worktrees are pruned on merge completion and swept by task state.

- prune pre-existing same-task AI merge temp worktrees before starting a new merge and audit cleanup outcomes
- add task-aware tempdir sweep rules with a short grace period for done or archived tasks and immediate cleanup for deleted tasks
- extend merger and self-healing coverage and document the updated stale worktree policy

Files changed:
 .changeset/ai-merge-cleanup-sweep.md               |   5 +
 docs/architecture.md                               |   2 +-
 packages/engine/src/__tests__/merger-ai-cleanup.test.ts | 109 ++++++++++++++++++--
 packages/engine/src/__tests__/self-healing-tempdir-sweep.test.ts   | 112 ++++++++++++++++++++-
 packages/engine/src/merger-ai.ts                   |  63 ++++++++++++
 packages/engine/src/self-healing.ts                |  26 ++++-
 6 files changed, 300 insertions(+), 17 deletions(-)

Fusion-Task-Id: FN-6199

Fusion-Task-Lineage: 659cc52f-0994-4315-a187-6c865bbe3983
2026-06-10 10:57:02 -07:00
gsxdsm
5c42ff1314 FN-6198: unquarantine self-healing db corruption test
Restore the self-healing DB corruption test to the default engine suite.

- remove the engine vitest exclude for self-healing-db-corruption.test.ts
- clear the quarantine ledger entry for the restored test

Files changed:
 packages/engine/vitest.config.ts | 1 -
 scripts/lib/test-quarantine.json | 8 +-------
 2 files changed, 1 insertion(+), 8 deletions(-)

Fusion-Task-Id: FN-6198

Fusion-Task-Lineage: 2466b040-956d-4138-89d5-137d1721081c
2026-06-10 10:00:21 -07:00
gsxdsm
ae63cd9008 FN-6195: isolate and quarantine flaky db-corruption test
Stop the self-healing DB corruption test from leaking into unrelated tmpdir state while quarantining the known flake.

- mock node:os tmpdir usage so the test runs inside a per-test sandbox and cleans it up after each case
- add the flaky self-healing DB corruption test to the engine default exclude list
- record the quarantine entry and failure context in scripts/lib/test-quarantine.json

Files changed:
 .../__tests__/self-healing-db-corruption.test.ts   | 22 ++++++++++++++++++++++
 packages/engine/vitest.config.ts                   |  1 +
 scripts/lib/test-quarantine.json                   |  8 +++++++-
 3 files changed, 30 insertions(+), 1 deletion(-)

Fusion-Task-Id: FN-6195

Fusion-Task-Lineage: 60f7f6ca-d14d-42b4-b47e-0644a25e64ae
2026-06-10 08:25:31 -07:00
gsxdsm
bbf3de97a0 FN-6193: guard merger settings lookup for deleted tasks
Keep AI merge commit finalization running when the task disappears during settings resolution.

- fall back to a synthetic task stub before merging effective settings in runAiAgentForCommit
- add an engine regression test covering deleted-task settings degradation
- add a patch changeset for the published CLI package

Files changed:
 .changeset/fn-6193-merger-deleted-task.md          |  5 +++
 .../src/__tests__/merger-settings-degrade.test.ts  | 43 ++++++++++++++++++++++
 packages/engine/src/merger.ts                      |  3 +-
 3 files changed, 50 insertions(+), 1 deletion(-)

Fusion-Task-Id: FN-6193

Fusion-Task-Lineage: 1d63d24e-1321-450c-95c9-ffc058fd8387
2026-06-10 08:07:25 -07:00
gsxdsm
4032a35a2f FN-6188: harden AI merge temp worktree cleanup
Improve AI merge temp worktree cleanup and add recovery coverage.

- audit AI merge clean-room cleanup success and failure paths, including stderr/code details
- sweep stale fusion-ai-merge temp directories from tmpdir() during self-healing with active-session safeguards
- document the native temp-dir sweep behavior and add merge cleanup/self-healing regression tests

Files changed:
 docs/architecture.md                               |   1 +
 .../engine/src/__tests__/merger-ai-cleanup.test.ts | 169 +++++++++++++++++
 .../__tests__/self-healing-tempdir-sweep.test.ts   | 200 +++++++++++++++++++++
 packages/engine/src/merger-ai.ts                   |  54 +++++-
 packages/engine/src/run-audit.ts                   |  26 +++
 packages/engine/src/self-healing.ts                | 105 +++++++++++
 6 files changed, 551 insertions(+), 4 deletions(-)

Fusion-Task-Id: FN-6188

Fusion-Task-Lineage: eae9bcdc-9765-4104-85dc-81bb50445e99
2026-06-10 05:13:40 -07:00
gsxdsm
5b5cd77021 FN-6177: remove queued-concurrency scheduler audit
Remove the write-only queued-concurrency scheduler audit and its stale documentation.

- delete scheduler:dispatch-queued-concurrency audit emission and memo bookkeeping
- keep queued concurrency log dedupe coverage while removing audit-specific scheduler test assertions
- update architecture docs to describe queued concurrency diagnostics as log output only

Files changed:
 docs/architecture.md                            |  4 +-
 packages/engine/src/__tests__/scheduler.test.ts | 33 ----------------
 packages/engine/src/scheduler.ts                | 51 -------------------------
 3 files changed, 2 insertions(+), 86 deletions(-)

Fusion-Task-Id: FN-6177

Fusion-Task-Lineage: e4516b41-5525-4e26-9602-772302d63f3d
2026-06-10 00:39:22 -07:00
gsxdsm
c9d48fb750 FN-6180: fix stale dashboard asset reload handling
Prevent rebuilt dashboard tabs from reusing stale cached assets after a deploy.

- revalidate service-worker asset requests against the network before falling back to cache and bump the cache version
- suppress repeated version-change reloads for the same remote build and cover the new behavior with dashboard tests
- update engine heartbeat test expectations for summarized task creation metadata and add the published package changeset

Files changed:
 .changeset/fn-blank-page-service-worker-assets.md  |  3 ++
 packages/dashboard/app/__tests__/pwa.test.ts       | 11 ++++++
 packages/dashboard/app/__tests__/versionCheck.test.ts   | 28 ++++++++++++++
 packages/dashboard/app/public/sw.js                | 37 +++++++++++++++++-
 packages/dashboard/app/versionCheck.ts             | 45 ++++++++++++++++++++++
 packages/engine/src/__tests__/heartbeat-executor.test.ts |  3 +-
 packages/engine/src/__tests__/heartbeat-session-prompt.test.ts |  7 +++-
 7 files changed, 131 insertions(+), 3 deletions(-)

Fusion-Task-Id: FN-6180

Fusion-Task-Lineage: 4f07e5f0-56c7-4241-8719-f576dfd8613e
2026-06-10 00:20:35 -07:00
gsxdsm
e326c5e8db FN-6174: remove overlap priority inversion audit
Remove the unused scheduler overlap-priority inversion audit path.

- drop the scheduler memoization and audit emission for overlap-priority inversion blockers
- delete the reliability interaction test that only covered the removed audit behavior
- update architecture documentation to note the audit removal and keep the overlap deferral rule

Files changed:
 docs/architecture.md                               |   3 +-
 packages/engine/src/__tests__/reliability-interactions/scheduler-overlap-priority-inversion.test.ts   | 212 ---------------------
 packages/engine/src/scheduler.ts                   |  51 -----
 3 files changed, 1 insertion(+), 265 deletions(-)

Fusion-Task-Id: FN-6174

Fusion-Task-Lineage: 3062b405-1f1d-473d-a02f-09a1077376c0
2026-06-09 23:37:31 -07:00
gsxdsm
1c875f1704 FN-6172: fix skill diagnostics logger assertion
Update the skill diagnostics test to assert against the structured logger surface that now emits the diagnostics output.

- spy on piLog.log instead of piLog.warn in the structured logger diagnostics test
- keep the existing [skills] and [executor] assertions while matching the current logging path

Files changed:
 packages/engine/src/__tests__/pi-create-fn-agent.test.ts | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Fusion-Task-Id: FN-6172

Fusion-Task-Lineage: e52023f7-6c18-435d-b2c6-bd7f7024b75f
2026-06-09 23:26:13 -07:00
gsxdsm
1b7e52ea99 FN-6168: expose workflow routing in triage
Add workflow discovery, selection, and investigation-task routing guidance to triage.

- document workflow routing guidance in standard and fast triage prompts
- add workflow list/select tools to triage sessions for task specification
- pass workflow_id and noCommitsExpected through fn_task_create for child tasks
- cover prompt/tool availability and child-task routing in triage tests
- add a changeset and workflow docs for triage workflow selection behavior

Files changed:
 .changeset/fn-6168-triage-workflow-routing.md |  5 ++
 docs/workflow-steps.md                        |  2 +
 packages/engine/src/__tests__/triage.test.ts  | 93 +++++++++++++++++++++++++++
 packages/engine/src/triage.ts                 | 27 ++++++++
 4 files changed, 127 insertions(+)

Fusion-Task-Id: FN-6168

Fusion-Task-Lineage: acfcebd5-bb9c-42ba-90a0-e9bcb90216b3
2026-06-09 22:34:34 -07:00
gsxdsm
4d7c51d526 FN-6164: route agent task title summarization through the store
Ensure agent-created tasks use store-managed title summarization before creation hooks fire.

- resolve a store-managed summarizer when task creation explicitly requests summarization
- defer the task-created hook until store summarization finishes and persists the generated title
- stop agent tools from wiring ad hoc summarizer callbacks and pass resolved settings through to createTask
- update core and engine tests to cover store-managed summarization, hook deferral, and inherited settings expectations

Files changed:
 packages/core/src/__tests__/store-create.test.ts  | 83 +++++++++++++++++++++++
 packages/core/src/store.ts                        |  7 +-
 packages/engine/src/__tests__/agent-tools.test.ts | 70 +++++++++----------
 packages/engine/src/__tests__/triage.test.ts      | 12 +++-
 packages/engine/src/agent-tools.ts                | 10 +--
 5 files changed, 136 insertions(+), 46 deletions(-)

Fusion-Task-Id: FN-6164

Fusion-Task-Lineage: f8da7bd7-b5d4-4505-98ed-60c19d82904c
2026-06-09 22:18:48 -07:00
gsxdsm
4435ca2c54 FN-6158: handle Codex auth-tier model incompatibility
Gracefully recover from unsupported Codex model selections on ChatGPT-account auth tiers.

- detect Codex and general model-auth-tier incompatibility errors as retryable model-selection failures
- trigger configured fallback models during session creation and prompt-time retries, with actionable operator guidance when no fallback works
- document the expanded fallback behavior and add engine regression coverage plus a CLI changeset

Files changed:
 .changeset/fn-6158-model-compatibility-fallback.md |   5 +
 docs/settings-reference.md                         |   2 +-
 .../pi-prompt-session-and-check-recursion.test.ts  |  25 ++++
 packages/engine/src/__tests__/pi.test.ts           | 136 ++++++++++++++++++++-
 .../src/__tests__/transient-error-detector.test.ts |  24 ++++
 packages/engine/src/pi.ts                          |  21 +++-
 packages/engine/src/transient-error-detector.ts    |  24 ++++
 7 files changed, 234 insertions(+), 3 deletions(-)

Fusion-Task-Id: FN-6158
Fusion-Task-Lineage: 3e91f647-40f1-4296-afa4-40861310e1c1
2026-06-09 21:16:42 -07:00
gsxdsm
a57167e96a FN-6140: downgrade missing skill diagnostics to info
Reduce noise from missing requested skill messages in agent logs.

- change missing requested skill diagnostics from warning to info in the skill resolver
- update engine tests to expect info-level logging for unresolved requested skills
- preserve the built-in fusion fallback behavior without emitting not-found diagnostics

Files changed:
 packages/engine/src/__tests__/pi.test.ts           |  6 ++--
 packages/engine/src/__tests__/skill-resolver.test.ts    | 42 +++++++++++-----------
 packages/engine/src/skill-resolver.ts              |  2 +-
 3 files changed, 25 insertions(+), 25 deletions(-)

Fusion-Task-Id: FN-6140

Fusion-Task-Lineage: 3d2efdcd-8c6d-4fda-b5cb-b85421ac755e
2026-06-09 15:50:53 -07:00
gsxdsm
b7a56cc399 FN-6141: stop treating benign workflow-graph exits as failures
Treat already-finalized or paused workflow-graph exits as benign instead of failure-worthy.

- log info-level benign messages when workflow graph runs end after a task is paused or has already advanced out of in-progress
- keep true in-progress graph failures on the existing failed-and-handoff path with failure logging
- add executor recovery coverage for todo, in-review, done, paused, and genuine failure cases
- add a patch changeset for the published CLI package

Files changed:
 .changeset/fn-6141-benign-graph-exit.md            |   5 +
 .../engine/src/__tests__/executor-recovery.test.ts | 137 ++++++++++++++++++++-
 packages/engine/src/executor.ts                    |  23 ++--
 3 files changed, 150 insertions(+), 15 deletions(-)

Fusion-Task-Id: FN-6141

Fusion-Task-Lineage: 8d29159a-8d7a-4e84-b05a-fe83f6ccbb78
2026-06-09 15:27:57 -07:00
gsxdsm
2fe12ad261 FN-6139: remove unused _baseSha parameter
Remove the unused _baseSha parameter from branch authority checks.

- delete the unused optional _baseSha parameter from isBranchAuthoritativeForTask
- keep branch authority behavior unchanged while simplifying the function signature

Files changed:
 packages/engine/src/branch-conflicts.ts | 1 -
 1 file changed, 1 deletion(-)

Fusion-Task-Id: FN-6139

Fusion-Task-Lineage: 349144fd-2f4a-4a19-a13f-14b2786e97ef
2026-06-09 15:21:39 -07:00
gsxdsm
ceec6fa1e4 FN-6138: log missing skill patterns at info level
Downgrade configured-skill pattern misses from warnings to informational diagnostics.

- change missing allowed-skill pattern diagnostics from warning to info in the skill resolver
- update skill resolver tests to expect informational diagnostics and piLog.log output

Files changed:
 packages/engine/src/__tests__/skill-resolver.test.ts | 21 ++++++++++-----------
 packages/engine/src/skill-resolver.ts               |  2 +-
 2 files changed, 11 insertions(+), 12 deletions(-)

Fusion-Task-Id: FN-6138

Fusion-Task-Lineage: 4bb7ddf8-5ae8-46c6-8fec-b4940a1bb39f
2026-06-09 15:17:02 -07:00
gsxdsm
b5d19bd480 FN-6134: extend surface-enumeration gates to UI affordance changes
Apply the surface-enumeration review gate to UI affordance add/remove work across triage, review, tests, and docs.

- require triage prompts to add Surface Enumeration guidance for UI affordance add/remove tasks in standard and fast modes
- tighten reviewer guidance to block single-surface UI affordance coverage and leftover shell cleanup gaps
- expand engine prompt tests to cover the new UI affordance gate wording
- document the shared checklist and motivating incidents in AGENTS.md and docs/testing.md

Files changed:
 AGENTS.md                                      |  3 +++
 docs/testing.md                                |  6 +++++-
 packages/engine/src/__tests__/reviewer.test.ts | 26 ++++++++++++++++++++++++--
 packages/engine/src/__tests__/triage.test.ts   | 19 ++++++++++++++++++-
 packages/engine/src/reviewer.ts                |  5 +++--
 packages/engine/src/triage.ts                  | 24 ++++++++++++++----------
 6 files changed, 67 insertions(+), 16 deletions(-)

Fusion-Task-Id: FN-6134

Fusion-Task-Lineage: 0bc733eb-d160-48cc-817d-69138290faec
2026-06-09 15:12:26 -07:00
gsxdsm
7f08845ed5 FN-6130: make compound engineering theme colors dark-mode aware
Align compound engineering dashboard colors with the active theme tokens.

- replace hardcoded and legacy compound engineering CSS colors with dashboard theme tokens
- switch dimmed text treatments from opacity to explicit theme-aware text tokens for light and dark mode
- add regression coverage for token usage in compound engineering styles
- keep branch authority checks compatible with the optional base SHA argument

Files changed:
 packages/engine/src/branch-conflicts.ts            |   1 +
 .../src/dashboard/CompoundEngineeringView.css      | 106 +++++++++++----------
 .../src/dashboard/__tests__/theme-tokens.test.ts   |  97 +++++++++++++++++++
 3 files changed, 153 insertions(+), 51 deletions(-)

Fusion-Task-Id: FN-6130

Fusion-Task-Lineage: 00adc217-0649-4b4f-9b9b-92c551f02926
2026-06-09 14:56:26 -07:00
gsxdsm
5f1fe3f57b FN-6132: remove unused base SHA from branch authority check
Fix the branch authority helper and caller so the squash merge stays lint-clean.

- drop the unused `baseSha` parameter from `isBranchAuthoritativeForTask`
- update the merger authority probe to call the helper with the remaining arguments

Files changed:
 packages/engine/src/branch-conflicts.ts | 1 -
 packages/engine/src/merger.ts           | 2 +-
 2 files changed, 1 insertion(+), 2 deletions(-)

Fusion-Task-Id: FN-6132
Fusion-Task-Lineage: c8d8352d-67f7-498b-8b6d-254375d42417
2026-06-09 14:45:15 -07:00
gsxdsm
576ff7768a fix(FN-6131): stop failing on foreign branch attribution
Treat foreign task-attributed commits in branch ranges as informational instead of blocking worktree acquisition or branch authority checks.

Fusion-Task-Id: FN-6131
2026-06-09 14:32:13 -07:00
gsxdsm
b872b37d72 FN-6117: expose task attachments in workflow step prompts
Make workflow-driven task execution keep attachment context available across step prompts and retries.

- add attachment guidance to full step prompts so agents can read project-root task attachments from worktrees
- include attachment availability in reduced retry prompts after context-limit failures
- cover attachment preservation through workflow runtime execution and step prompt generation with engine tests

Files changed:
 .../src/__tests__/step-session-executor.test.ts    | 272 +++++++++++++++++++++
 .../src/__tests__/workflow-task-runtime.test.ts    |  94 ++++++-
 packages/engine/src/step-session-executor.ts       |  13 +-
 3 files changed, 376 insertions(+), 3 deletions(-)

Fusion-Task-Id: FN-6117

Fusion-Task-Lineage: 520eb1bc-e276-449a-acfe-ccbabefe69e3
2026-06-09 13:31:30 -07:00
gsxdsm
320b153c45 FN-6113: fail fast on terminal provider errors
Fail fast on non-retryable provider failures in the in-review stall recovery flow.

- classify failed-task provider errors as non-retryable, retryable, or unknown in core stall detection
- surface terminal provider errors with dedicated dashboard copy and exported stall signal metadata
- pause in-review tasks immediately on non-retryable provider failures and record a dedicated run-audit mutation
- add regression coverage for provider error classification, self-healing disposition, and dashboard badge behavior

Files changed:
 .../core/src/__tests__/in-review-stall.test.ts     |  70 ++++++++++
 packages/core/src/in-review-stall.ts               |  53 ++++++-
 packages/core/src/index.ts                         |   4 +-
 .../app/utils/__tests__/inReviewStallCopy.test.ts  |   5 +-
 packages/dashboard/app/utils/inReviewStallCopy.ts  |   8 ++
 .../in-review-stall-deadlock-disposition.test.ts   | 153 +++++++++++++++++++++
 packages/engine/src/run-audit.ts                   |   1 +
 packages/engine/src/self-healing.ts                |  30 +++-
 8 files changed, 320 insertions(+), 4 deletions(-)

Fusion-Task-Id: FN-6113

Fusion-Task-Lineage: 5e89adb4-6b59-4deb-8811-5c75d6fa19cc
2026-06-09 12:51:20 -07:00
gsxdsm
934071cc3c FN-6107: always summarize untitled agent-created tasks
Ensure agent-created untitled tasks still request AI-generated titles even when project auto-summarization is disabled.

- force summarize=true for agent-created tasks that do not provide an explicit title
- add engine tests covering untitled, titled, and title-generation behavior with autoSummarizeTitles disabled
- document the agent-task summarization behavior in settings docs
- add a patch changeset for the published CLI package

Files changed:
 .changeset/agent-task-title-summaries.md          |  5 ++
 docs/settings-reference.md                        |  2 +-
 packages/engine/src/__tests__/agent-tools.test.ts | 63 +++++++++++++++++++++++
 packages/engine/src/agent-tools.ts                |  1 +
 4 files changed, 70 insertions(+), 1 deletion(-)

Fusion-Task-Id: FN-6107

Fusion-Task-Lineage: d0c25981-a5cb-48ca-b835-9267817b4edd
2026-06-09 12:51:20 -07:00
gsxdsm
6271778dde FN-6091: add workflow_id support to task tools
Add workflow selection support across task creation, delegation, and updates.

- add workflow_id parameters and response text for engine and CLI task-creation/delegation tools
- allow fn_task_update to select or clear task workflows with reconciliation and validation
- cover workflow selection behavior with engine and extension tests and document the new tool parameters
- add a changeset for the published CLI package

Files changed:
 .changeset/fn-6091-workflow-id-agent-tools.md      |   5 +
 .../cli/skill/fusion/references/engine-tools.md    |   4 +-
 .../cli/skill/fusion/references/extension-tools.md |   9 +-
 .../skill/fusion/references/fusion-capabilities.md |   6 +-
 packages/cli/src/__tests__/extension.test.ts       | 189 +++++++++++++++++++++
 packages/cli/src/extension.ts                      |  71 +++++++-
 packages/engine/src/__tests__/agent-tools.test.ts  |  78 +++++++++
 packages/engine/src/agent-tools.ts                 |  32 +++-
 8 files changed, 374 insertions(+), 20 deletions(-)

Fusion-Task-Id: FN-6091

Fusion-Task-Lineage: 7ab2f36a-feeb-4888-9845-65294bacf1d0
2026-06-09 12:51:20 -07:00
gsxdsm
d240fb8735 FN-6108: mock gh auth in github-tracking engine tests
Stabilize engine github-tracking tests by fully mocking gh auth-dependent modules.

- hoist github-tracking module paths and replace maybeCreateTrackingIssue with shared vi mocks
- mock @fusion/core gh availability/auth helpers so dashboard tracking hooks do not touch real gh-cli state
- switch per-test cleanup from restoreAllMocks to clearAllMocks and import mocked hook helpers directly

Files changed:
 ...gent-task-creation-github-tracking-flag.test.ts | 44 ++++++++++++++--------
 .../agent-tools-github-tracking-end-to-end.test.ts | 43 ++++++++++++++-------
 2 files changed, 58 insertions(+), 29 deletions(-)

Fusion-Task-Id: FN-6108

Fusion-Task-Lineage: c7e9aac2-9687-45d5-9b96-233421aa19eb
2026-06-09 12:51:20 -07:00
gsxdsm
0b0186a22e fix(FN-6088): suppress queued merge stalled badges
Suppress legacy stalledReview hydration for tasks already owned by the merge queue and avoid repeated mergeable-review re-enqueue churn for queued tasks.

Fusion-Task-Id: FN-6088
2026-06-09 12:50:26 -07:00
gsxdsm
55ba994ae9 FN-6096: run worktree init command in post-merge worktrees
Run the configured worktree init command before post-merge workflow steps use their temporary worktree.

- execute the configured worktreeInitCommand inside isolated post-merge worktrees before workflow steps run
- log successful and failed post-merge init outcomes while keeping workflow-step execution non-fatal on init failure
- add merger tests covering configured init execution, missing init configuration, and init-command failure handling

Files changed:
 packages/engine/src/__tests__/merger-post-merge.test.ts | 156 +++++++++++++++++++++
 packages/engine/src/merger.ts                      |  71 +++++++++-
 2 files changed, 226 insertions(+), 1 deletion(-)

Fusion-Task-Id: FN-6096

Fusion-Task-Lineage: 32ba5e62-cffd-4d94-bd23-a7ce2df3cbf9
2026-06-09 12:50:26 -07:00
gsxdsm
07a5365115 FN-6093: fix ntfy workflow notification delivery
Ensure workflow and merge-triggered ntfy notifications fire reliably.

- preserve merge-backed task metadata before moving tasks to done so merged notifications retain context
- treat an empty ntfy event allowlist as the documented default event set
- allow failed or no-provider notification attempts to clear dedupe state and retry after settings refresh
- add regression coverage for workflow notify dispatch, stale-settings refresh, and merged-task ntfy delivery

Files changed:
 .changeset/fn-6093-notification-workflow-fix.md    |   5 +
 packages/engine/src/__tests__/merger-ai.test.ts    |   9 +-
 packages/engine/src/__tests__/notification-service.test.ts     | 165 +++++++++++++++++++++
 packages/engine/src/merger-ai.ts                   |  18 ++-
 packages/engine/src/notification/notification-service.ts       |  14 +-
 packages/engine/src/notifier.ts                    |   2 +-
 6 files changed, 208 insertions(+), 5 deletions(-)

Fusion-Task-Id: FN-6093

Fusion-Task-Lineage: fc42cb94-f542-4a34-a325-ffb55dea02f4
2026-06-09 12:50:26 -07:00
gsxdsm
7a9d2b0f30 fix(FN-6086): preserve merge-queued review tasks
Treat persisted merge queue ownership as an active merge-lane owner when hydrating in-review stall state and when self-healing scans for ghost, stalled, or completion-handoff-limbo tasks.

Also clear false completion-handoff exhaustion for tasks that are still owned by the merge queue so previously poisoned review tasks can continue merging.

Fusion-Task-Id: FN-6086
2026-06-09 09:41:28 -07:00
gsxdsm
38d7f1c436 FN-6087: skip completed foreach steps on resume
Prevent shared-isolation foreach resumes from re-running terminal task steps.

- skip foreach step instances whose persisted status is already done or skipped before launching step-execute
- log resume skips so restart behavior is auditable during shared-isolation foreach runs
- add regression coverage for all-done resumes, mixed done/skipped resumes, and in-progress step replays

Files changed:
 .../src/__tests__/workflow-graph-foreach.test.ts   | 85 ++++++++++++++++++++++
 packages/engine/src/workflow-graph-foreach.ts      | 13 ++++
 2 files changed, 98 insertions(+)

Fusion-Task-Id: FN-6087

Fusion-Task-Lineage: 56805a5c-a1ea-41bc-a758-1afed83c6bb7
2026-06-09 09:00:46 -07:00
gsxdsm
ccd44b77fe fix(FN-6085): canonicalize merge worktree boundaries 2026-06-09 08:51:48 -07:00
gsxdsm
5f5852db8f fix(FN-6085): accept canonical merge worktree paths 2026-06-09 08:43:20 -07:00
gsxdsm
a53330786e fix(FN-6082): restore workflow overlap blocking
Workflow-column hold releases now participate in active file-scope leases before moving tasks into in-progress, preserving overlapBlockedBy card badges and scheduler blocking.

Fusion-Task-Id: FN-6082
2026-06-09 08:02:56 -07:00
gsxdsm
cd8126d6a4 fix(FN-6084): honor worktree limit for hold releases
Workflow-column hold releases now reserve against the active worktree count before moving tasks into in-progress, preventing restart bursts from exceeding maxWorktrees.

Fusion-Task-Id: FN-6084
2026-06-09 07:55:45 -07:00
gsxdsm
df74a6b752 FN-6050: stop re-emitting existing mission advisories
Treat previously recorded unlinked-mission advisories as authoritative across insight states.

- remove the generated-only insight filter when checking for an existing unlinked mission advisory
- suppress duplicate advisories even when the existing insight is dismissed, archived, or confirmed
- expand reporter coverage to assert the broader duplicate-detection behavior and insight query shape

Files changed:
 .../unlinked-missions-advisory-reporter.test.ts    | 49 +++++++++++++---------
 .../src/unlinked-missions-advisory-reporter.ts     |  1 -
 2 files changed, 29 insertions(+), 21 deletions(-)

Fusion-Task-Id: FN-6050

Fusion-Task-Lineage: 5b9274f7-baf6-40c1-8a88-2fcc86c7ef14
2026-06-09 03:53:34 -07:00
gsxdsm
5030e2963e FN-6070: fix completion-handoff limbo recovery accounting
Ensure limbo recovery attempts count only when auto-merge requeue is actually accepted.

- require completion-handoff recovery to enqueue merge work and confirm the requeue callback accepted the handoff before incrementing recovery counters
- return a boolean from the in-process runtime auto-merge requeue hook so self-healing can distinguish accepted versus rejected handoffs
- add coverage for rejected requeues, accepted retries, exhaustion behavior, and stalled in-review tasks that should not be deadlocked by rejected limbo recoveries

Files changed:
 .../completion-handoff-limbo.test.ts               | 126 ++++++++++++++++-----
 .../in-review-stall-deadlock-disposition.test.ts   |  43 +++++++
 packages/engine/src/runtimes/in-process-runtime.ts |   2 +-
 packages/engine/src/self-healing.ts                |  42 ++++---
 4 files changed, 170 insertions(+), 43 deletions(-)

Fusion-Task-Id: FN-6070

Fusion-Task-Lineage: 9634dc24-6045-4ee2-baec-d6e1d71a46b1
2026-06-09 03:44:20 -07:00
gsxdsm
eb113f3e33 FN-6068: fix engine executor test expectations for queued retries
Align engine executor tests with the current retry and worktree behavior.

- update implicit task-done refusal expectations to assert queued retry state resets
- update pause recovery coverage to expect requeued tasks instead of stuck-killed status
- stub the sandbox backend in worktree init tests and drop obsolete execSync assertions

Files changed:
 .../executor-implicit-task-done-budget.test.ts     | 11 ++++++-
 ...xecutor-implicit-task-done-revise-guard.test.ts | 11 ++++++-
 .../engine/src/__tests__/executor-pause.test.ts    |  5 +--
 .../engine/src/__tests__/executor-worktree.test.ts | 37 ++++++++++++++++------
 4 files changed, 50 insertions(+), 14 deletions(-)

Fusion-Task-Id: FN-6068

Fusion-Task-Lineage: b8ccabaa-7e5d-42dc-b522-6f4738b28db4
2026-06-09 02:27:43 -07:00
gsxdsm
e5e5ccf01f FN-6065: fix pending-review advisory retry expectation
Adjust the reliability test to match the queued advisory retry path.

- update the plan-review UNAVAILABLE assertion to expect the task to requeue instead of fail
- assert the advisory path clears the error while incrementing the retry counter
- keep coverage that pending review should not record the executor review-pending failure

Files changed:
 packages/engine/src/__tests__/reliability-interactions/executor-pending-review-skip-retry.test.ts | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

Fusion-Task-Id: FN-6065

Fusion-Task-Lineage: 1ef13146-f19b-4735-9ec5-3f00eff6e575
2026-06-09 02:15:03 -07:00
gsxdsm
4b4c32dc18 FN-6063: enforce workflow scheduling capacity after hold release
Keep scheduler capacity checks aligned with fresh task state during workflow dispatch.

- bypass the startup slim-list memo when scheduling and after workflow hold release sweeps
- clear the startup slim-list memo when task.json writes move tasks between columns
- treat capacity-exhausted moveTask rejections as queued dispatches, log the reason, and cover the behavior with scheduler/store tests
- add a patch changeset for the published CLI package

Files changed:
 .changeset/workflow-capacity-scheduler.md          |  5 +++
 packages/core/src/__tests__/store-movement.test.ts | 15 ++++++++
 packages/core/src/store.ts                         |  1 +
 packages/engine/src/__tests__/scheduler.test.ts    | 40 ++++++++++++++++++++--
 packages/engine/src/scheduler.ts                   | 25 ++++++++++----
 5 files changed, 77 insertions(+), 9 deletions(-)

Fusion-Task-Id: FN-6063

Fusion-Task-Lineage: 80ddc0e7-f78d-483c-886a-27c4c07bde7a
2026-06-09 02:03:22 -07:00
gsxdsm
13c6d96fe1 FN-6031: add workflow notification nodes
Add workflow notify nodes with templated notification dispatch support.

- add notify node support to workflow IR, engine handlers, and executor wiring
- expose notify node configuration and summaries in the dashboard editor and node metadata
- add regression tests and a published changeset, plus workflow/settings documentation updates

Files changed:
 .changeset/fn-6031-notification-node.md            |   5 +
 docs/settings-reference.md                         |   6 +-
 docs/workflow-steps.md                             |  10 +-
 packages/core/src/__tests__/workflow-ir.test.ts    |  59 ++++++++++
 packages/core/src/types.ts                         |   4 +-
 packages/core/src/workflow-ir-types.ts             |   4 +-
 packages/core/src/workflow-ir.ts                   |  19 +++
 packages/dashboard/app/components/WorkflowNodeEditor.tsx          |  76 +++++++++++-
 packages/dashboard/app/components/__tests__/WorkflowNodeEditor.test.tsx          |  61 ++++++++++
 packages/dashboard/app/components/__tests__/node-summary.test.ts  |  29 +++++
 packages/dashboard/app/components/__tests__/workflow-flow-mapping.test.ts        |  37 ++++++
 packages/dashboard/app/components/nodes/WorkflowNodeTypes.tsx     |   7 +-
 packages/dashboard/app/components/nodes/node-summary.ts |   5 +
 packages/engine/src/__tests__/workflow-node-handlers-notify.test.ts          | 131 +++++++++++++++++++++
 packages/engine/src/executor.ts                    |   2 +
 packages/engine/src/notification/ntfy-provider.ts  |  11 ++
 packages/engine/src/notification/webhook-provider.ts    |   6 +-
 packages/engine/src/workflow-graph-executor.ts     |   4 +
 packages/engine/src/workflow-graph-task-runner.ts  |   4 +
 packages/engine/src/workflow-node-handlers.ts      |  93 ++++++++++++++-
 20 files changed, 560 insertions(+), 13 deletions(-)

Fusion-Task-Id: FN-6031

Fusion-Task-Lineage: ff5c91e2-3872-4264-9c18-5d9e11628f13
2026-06-09 01:57:16 -07:00
gsxdsm
f27ebfd6bb FN-6051: add workflow graph retry coverage
Add retry coverage for built-in coding workflow executor failures.

- add execute-node retry tests for transient exceptions, exhausted retries, and clean failure outcomes
- verify review nodes use default retry behavior when no per-node retry config exists
- cover per-node maxRetries overrides with a custom workflow IR

Files changed:
 packages/engine/src/__tests__/workflow-graph-executor-retry-coding-workflow.test.ts | 133 +++++++++++++++++++++
 1 file changed, 133 insertions(+)

Fusion-Task-Id: FN-6051

Fusion-Task-Lineage: a2232af7-a86d-4ce4-aab9-a2cc18694f8a
2026-06-09 00:44:48 -07:00
gsxdsm
40d05c8139 fix(FN-6035): address workflow projection review feedback 2026-06-09 00:01:00 -07:00
gsxdsm
ad68c9d612 fix(FN-6035): harden workflow projection publishing 2026-06-08 23:47:33 -07:00
gsxdsm
83565a535a fix(FN-6035): project workflow dispatch metadata 2026-06-08 23:38:32 -07:00
gsxdsm
9c43e3f30e Merge pull request #1539 from Runfusion/feature/workflow-mapping
fix(FN-6035): align workflow dispatch and broad suite
2026-06-08 23:06:53 -07:00
gsxdsm
a98713d01d fix(FN-6035): cap scheduler dispatch by global slots 2026-06-08 22:47:51 -07:00
gsxdsm
1029a1b8b4 test(FN-6035): fix broad workflow suite expectations 2026-06-08 22:35:04 -07:00