Commit Graph

13238 Commits

Author SHA1 Message Date
gsxdsm
cdf81a2244 fix(FN-8826): retry partial workflow progress after restart
Fusion-Task-Id: FN-8826
2026-08-07 16:55:00 -07:00
gsxdsm
ef8828f145 fix: unblock workflow execution stalled by silent role-routing deadlocks
Every task sat in progress with no session, no log, and no error after the
FN-8764 role-agent rollout. Two independent deadlocks, both invisible:

1. The in-process runtime built its AgentStore but never passed it into
   TaskExecutorOptions, so the executor's fail-closed role-routing gate refused
   every classified node (execute/step-execute/review/merge).
2. A resumed run keeps the continuation work item it woke on active until the
   interpreter returns, so the next node's principal-fence upsert violated
   idx_workflow_work_items_one_active_task_continuation — a different index than
   its ON CONFLICT target — and raised. The run re-suspended on every dispatch;
   only an operator bouncing the card to the hold column cleared it.

Both refusals were swallowed as recoverable "principal holds" that write no log,
audit row, or task error, which is why a fully deadlocked board looked idle.

- Wire agentStore into the executor; assert the shared instance at every runtime
  seam in the PG composition test.
- Supersede an active work item for a node the run has already left, then retry
  the fence write once; never touch a claim on the node currently executing.
- Record task:workflow-run-suspended and task:workflow-continuation-superseded;
  log principal holds, routing-unavailable faults, and fence-write errors.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 16:15:39 -07:00
gsxdsm
8c76416960 fix(FN-8801): synchronize dashboard pause state 2026-08-07 15:02:01 -07:00
gsxdsm
55e8484418 fix(FN-8764): refresh stale task activity feed 2026-08-07 15:01:21 -07:00
gsxdsm
1f9b0e644a fix(FN-8764): run built-in role provisioning on the locking transaction
provisionBuiltinWorkflowRoleAgents took a project-scoped pg_advisory_xact_lock
inside transactionImmediate, then ran provision() against the pool. The lock
holder therefore needed a SECOND pooled connection to finish while concurrent
callers occupied the remaining slots blocking on that same advisory lock. With
DEFAULT_POOL_MAX=3 this self-deadlocked: the holder could never complete, the
waiters could never take the lock, and every subsequent query -- that is, every
DB-backed API route -- queued forever behind an exhausted pool. Observed as a
dashboard that booted ("Ready in 6.5s") and then answered no /api request while
the event loop sat idle in kevent; pg_stat_activity showed one session idle in
transaction holding the lock and two active sessions waiting on it.

Thread an optional QueryHandle through listAgents, findAgentByName, createAgent,
and writeAgent so provisioning runs on tx and the lock and its work share one
connection.

Regression test bounds the pool to a single connection, which makes any second
checkout unsatisfiable and fails deterministically rather than racing. Verified
by reverting the one-line fix: the suite hangs past 300s instead of passing in
under 4s.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 08:51:05 -07:00
gsxdsm
039db99307 fix: restore Todos and Roadmaps plugin nav entries via manifest dashboardViews
Both plugins declared dashboardViews only in their src/index.ts module.
PluginLoader.getCurrentManifestDashboardViews treats a successfully-read
manifest as authoritative and returns an empty list when the key is absent,
and getPluginDashboardViews only falls back to the module definition when the
manifest read fails. The module-level entries were therefore discarded and
neither view appeared on any nav surface -- header overflow, desktop sidebar,
or mobile More sheet all consume the same array from usePluginDashboardViews.

Mirror the manifest shape used by fusion-plugin-compound-engineering.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 07:49:23 -07:00
gsxdsm
fc2040ca84 FN-8821: retire ephemeral-agent routing branches
Keep the legacy ephemeral-agent setting compatible while making all workflow routing durable-principal-only.

- Preserve and expose the legacy setting as a routing-inert compatibility field.
- Remove scheduler, executor, and mission-start branches that honored the deprecated toggle.
- Add coverage for settings persistence and durable routing invariants.

Files changed:
 .changeset/fn-8821-retire-ephemeral-routing.md     |   7 +
 docs/settings-reference.md                         |   4 +-
 .../core/src/__tests__/settings-parity.test.ts     |   8 +-
 packages/core/src/config/settings-schema.ts        |  11 +-
 packages/core/src/task-store/settings-helpers.ts   |  15 +-
 packages/core/src/task-store/settings-ops.ts       |  12 +-
 packages/core/src/types/settings/settings-scope.ts |   5 +-
 .../__tests__/SettingsModal.general.test.tsx       |  23 ++
 .../settings/sections/GeneralSection.tsx           |  13 ++
 .../src/__tests__/mission-start-routing.test.ts    | 104 +++++++++
 ...ecutor-ephemeral-disabled-dispatch-gate.test.ts | 243 +++++++++++++++++++++
 .../__tests__/scheduler-ephemeral-toggle.test.ts   | 125 +++++++++++
 12 files changed, 542 insertions(+), 28 deletions(-)

Fusion-Task-Id: FN-8821

Fusion-Task-Lineage: e81ec9c0-f2b0-48f9-ae2b-9bbde4491447

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-07 02:33:35 -07:00
gsxdsm
eaadd153b1 FN-8764: route workflow stages through durable role agents
Route workflow stages through task-scoped durable role agents.

- Persist normalized multi-role agents and workflow principal fences with migrations.
- Route planning, execution, review, and merge workflow nodes through authorized permanent principals with capacity leasing and recovery.
- Retire ephemeral workflow-stage workers and expose role-aware agent configuration, workflow editing, and documentation.
- Preserve lifecycle-column ratchet coverage by centralizing workflow-role classification rather than adding test exemptions.

Files changed:
 .changeset/fn-8764-workflow-role-agents.md         |   7 +
 CONCEPTS.md                                        |   3 +
 docs/agents.md                                     |   6 +
 docs/architecture.md                               |   6 +
 docs/cli-reference.md                              |   2 +
 docs/dashboard-guide.md                            |   4 +
 docs/settings-reference.md                         |   6 +-
 docs/storage.md                                    |   2 +
 docs/workflow-steps.md                             |   6 +
 .../src/__tests__/extension-agent-update.test.ts   |  11 +-
 packages/cli/src/__tests__/extension.test.ts       |  18 +-
 packages/cli/src/extension.ts                      |  41 +-
 .../core/src/__tests__/agent-permissions.test.ts   |  12 +
 .../core/src/__tests__/agent-role-policy.test.ts   |   7 +
 packages/core/src/__tests__/agent-roles.test.ts    |  21 +
 .../legacy-column-collection-gating-ledger.test.ts |  19 +-
 .../src/__tests__/postgres/schema-applier.test.ts  |  16 +-
 .../core/src/__tests__/settings-parity.test.ts     |   9 +-
 .../workflow-agent-node-classification.test.ts     |  25 +
 .../src/__tests__/workflow-work-item-cas.test.ts   |  38 ++
 packages/core/src/agents/agent-permissions.ts      |  11 +-
 packages/core/src/agents/agent-role-policy.ts      |  39 +-
 packages/core/src/agents/agent-store.ts            | 190 ++++++-
 .../core/src/async-stores/async-agent-store.ts     |   6 +
 packages/core/src/config/settings-schema.ts        |   5 +-
 packages/core/src/index.gate.ts                    |   2 +-
 packages/core/src/index.ts                         |   7 +-
 .../0045_fn_8764_multi_role_workflow_agents.sql    |  20 +
 .../0046_fn_8764_workflow_principal_fence.sql      |  49 ++
 packages/core/src/postgres/schema-applier.ts       |  22 +-
 packages/core/src/postgres/schema/project.ts       |  21 +
 packages/core/src/store.ts                         |   2 +-
 .../task-store/async/async-workflow-workitems.ts   |  49 +-
 packages/core/src/task-store/row-types.ts          |   4 +
 packages/core/src/task-store/settings-helpers.ts   |  16 +-
 packages/core/src/task-store/settings-ops-2.ts     |  13 +-
 packages/core/src/task-store/settings-ops.ts       |  16 +-
 packages/core/src/task-store/task-row-mappers.ts   |   4 +
 .../src/task-store/workflow-task-create-ops.ts     |   6 +-
 .../src/task-store/workflow-workitems-ops-2.ts     |  25 +-
 packages/core/src/types.ts                         |   2 +
 packages/core/src/types/agents/agents.ts           |  45 +-
 packages/core/src/types/merge/merge-queue.ts       |  17 +
 packages/core/src/types/settings/settings-scope.ts |   9 +-
 packages/core/src/workflows/workflow-ir-types.ts   |  58 +++
 packages/core/src/workflows/workflow-ir.ts         |  19 +
 .../dashboard/app/components/AgentDetailView.css   |  14 +
 .../dashboard/app/components/AgentDetailView.tsx   |  34 +-
 .../dashboard/app/components/NewAgentDialog.tsx    |  28 +-
 .../app/components/WorkflowNodeEditor.tsx          |  19 +
 .../__tests__/AgentDetailView.core.test.tsx        |   4 +-
 .../app/components/__tests__/AgentsView.test.tsx   |   2 +-
 .../__tests__/SettingsModal.general.test.tsx       |  86 ---
 .../__tests__/SettingsModal.test-harness.tsx       |   1 -
 .../components/agent-presets/agentCreatePayload.ts |   9 +-
 .../app/components/settings/section-keys.ts        |   1 -
 .../settings/sections/GeneralSection.tsx           |   8 -
 .../settings-default-descriptions.test.tsx         |   1 -
 .../app/components/workflow-flow-mapping.ts        |   7 +
 packages/dashboard/src/mission-routes.ts           |  26 +-
 .../src/routes/__tests__/agent-core-routes.test.ts |  23 +-
 .../src/routes/register-agent-core-routes.ts       |  42 +-
 ...gister-agent-import-export-generation-routes.ts |  21 -
 .../engine/src/__tests__/agent-action-gate.test.ts |  33 ++
 .../engine/src/__tests__/agent-assignment.test.ts  | 370 -------------
 .../src/__tests__/ephemeral-worker-manager.test.ts | 575 ---------------------
 ...ecutor-ephemeral-disabled-dispatch-gate.test.ts | 223 --------
 .../__tests__/executor-fast-mode-workflows.test.ts |  58 +++
 .../engine/src/__tests__/log-severity-manifest.ts  |   1 -
 .../__tests__/log-severity-spam-contract.test.ts   |   3 -
 .../resolved-read-with-literal-filter.test.ts      |   4 -
 .../__tests__/scheduler-ephemeral-toggle.test.ts   | 175 -------
 .../__tests__/scheduler-workflow-cutover.test.ts   |  19 -
 .../src/__tests__/workflow-agent-capacity.test.ts  |  47 ++
 .../src/__tests__/workflow-agent-routing.test.ts   | 137 +++++
 .../src/__tests__/workflow-graph-foreach.test.ts   |  15 +
 .../__tests__/workflow-graph-task-runner.test.ts   |  73 +++
 .../src/__tests__/workflow-task-runtime.test.ts    |  95 ++++
 .../src/__tests__/workflow-work-scheduler.test.ts  |  20 +
 packages/engine/src/agents/agent-action-gate.ts    |  64 +++
 packages/engine/src/agents/agent-assignment.ts     | 135 -----
 packages/engine/src/agents/agent-reflection.ts     |   1 +
 .../engine/src/agents/ephemeral-worker-manager.ts  | 429 ---------------
 .../engine/src/agents/workflow-agent-capacity.ts   | 113 ++++
 .../engine/src/agents/workflow-agent-router.ts     | 185 +++++++
 packages/engine/src/execution/reviewer.ts          |  26 +-
 packages/engine/src/executor.ts                    | 501 +++++++++++++++---
 packages/engine/src/index.ts                       |   1 -
 packages/engine/src/merger.ts                      |  20 +-
 packages/engine/src/pi.ts                          |  11 +
 packages/engine/src/runtimes/in-process-runtime.ts |  37 --
 packages/engine/src/scheduler.ts                   | 114 +---
 packages/engine/src/triage.ts                      | 196 ++++++-
 .../src/workflows/workflow-graph-executor.ts       | 109 +++-
 .../engine/src/workflows/workflow-graph-loop.ts    |  13 +-
 .../src/workflows/workflow-graph-task-runner.ts    |  12 +
 .../engine/src/workflows/workflow-task-runtime.ts  | 125 ++++-
 .../src/workflows/workflow-work-scheduler.ts       |   8 +-
 98 files changed, 2722 insertions(+), 2468 deletions(-)

Fusion-Task-Id: FN-8764
Fusion-Task-Lineage: 5527fccb-342d-46f6-8108-bbf89142efec
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-07 01:36:34 -07:00
ischindl
f7ca14beab feat(workflow): add fn_workflow_step_resume operator escape hatch for stuck pending merge-review steps (#3339)
## Summary

Adds an **operator-only** escape hatch for a card stranded `in-review`
(or `in-progress`) with a workflow step permanently stuck in `pending`
status — the leading real-world cause being a dispatched prompt node
(e.g. `code-review`) whose verdict callback was never received (see
#1946). Transitions the stuck `pending` pre-merge step to `status:
"failed"` with resume audit metadata, so the existing
`fn_task_bypass_review` escape hatch can then clear the merge blocker.

## What changed

- **`WorkflowStepResult`** gains resume audit fields: `resumedBy`,
`resumedAt`, `resumeReason`, `resumedFromStatus`. They are pure audit
trail and **do not** participate in merge-blocking
(`getTaskMergeBlocker`).
- **`findPendingPreMergeStep`** (new helper, exported from
`@fusion/core`) summarizes the stuck-pending pre-merge state for
operator tooling. Ignores post-merge steps; returns the newest pending
pre-merge result.
- **`TaskStore.resumeWorkflowStep(id, { stepId, reason, actor })`** —
the store primitive (eligibility-gated: task must be
`in-review`/`in-progress`, not paused; step must exist and be `pending`;
a mandatory non-blank `reason` and `stepId` are required). Runs under
`withTaskLock`, writes the resume as a terminal `failed` result, appends
a task-log breadcrumb, and emits the new `task:resume-step` run-audit
event.
- **`fn_workflow_step_resume`** — new CLI/pi-extension tool registered
**only** on the operator surface (deliberately **not** wired into
executor/reviewer/triage agent tool lists). Accepts `{ id, stepId,
reason }`; the actor defaults to `cli-operator`.
- **Run-audit**: new `task:resume-step` `DatabaseMutationType` member.

## Why

A prompt-node verdict callback can be lost (dispatched prompt never
receives a verdict), leaving the step `pending` forever. Previously the
only recourse was `fn_task_bypass_review`, which requires a terminal
*failed* pre-merge step to clear the blocker — a permanently `pending`
step could not be bypassed. This PR bridges that gap: resume (pending →
failed) then bypass (failed merge-blocker cleared).

## Verification

- **Typecheck**: `@fusion/core`, `@fusion/engine`, `@runfusion/fusion`
all clean.
- **`task-merge-bypass.test.ts`**: 15/15 pass (incl. 5 new
`findPendingPreMergeStep` cases).
- **`store-resume-step.test.ts`** (new, PG-backed): 9/9 pass —
eligibility gating, resume rewrite + audit fields, run-audit event,
non-pending/non-found/blank-argument rejection, in-progress column
support, property preservation.
- **`extension.test.ts`**: 75/75 pass (expected-tool registration
includes the new tool).

## Files

- `packages/core/src/types/workflow/workflow-steps.ts`
- `packages/core/src/merge/task-merge.ts`
- `packages/core/src/store.ts`
- `packages/core/src/index.ts`
- `packages/core/src/__tests__/store-resume-step.test.ts` (new)
- `packages/core/src/__tests__/task-merge-bypass.test.ts`
- `packages/engine/src/util/run-audit.ts`
- `packages/cli/src/extension.ts`
- `packages/cli/src/__tests__/extension.test.ts`
- `.changeset/stas-032-resume-workflow-step.md` (minor, feature)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Added an operator-only workflow recovery tool for permanently pending
pre-merge steps.
* Operators can mark eligible pending steps as failed by providing a
required audit reason.
* Recovery actions record operator details, timestamps, reasons, prior
status, task logs, and audit events.
* **Bug Fixes**
* Improved selection of the latest pending pre-merge workflow step while
excluding post-merge steps.
* Added validation to prevent recovery of paused, invalid, or
out-of-scope workflow steps.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: schindler <schindler@users.noreply.github.com>
Co-authored-by: gsxdsm <gsxdsm@users.noreply.github.com>
2026-08-07 00:26:15 -07:00
ischindl
4739f8aa67 fix: eagerly warm extension host stores from engine TaskStores (#3340)
## Summary

Warm the extension-host task stores **up front** at dashboard startup
instead of letting the first `fn_task_*` call lazily boot a second
PostgreSQL pool per project.

## What changed

`packages/cli/src/commands/dashboard.ts`:

- After the dashboard boots, iterate every registered project (from
`centralCoreForEngine.listProjects()`) and call
`setHostTaskStore(p.path, engine.getTaskStore())` for each non-cwd
project that already has a running `ProjectEngine`.
- Reuses each engine's **existing** `TaskStore` directly — no new
backend connection, no schema advisory-lock contention, no extra
connection-pool exhaustion.
- `cwd` is skipped because its store is already injected at startup.
- Per-project failures are non-fatal (warn) and a failed project listing
logs a single warn — dashboard startup never blocks on this.
- `.changeset/extension-host-store-warmup.md` (patch, fix).

## Why

Left on its own, the first extension tool call (`fn_task_update`,
`fn_task_archive`, `fn_agent_show`, …) for a non-cwd project falls
through to `createTaskStoreForBackend`, which boots a **second**
PostgreSQL connection pool on demand. On busy hosts that lazy boot can
time out, or the call stalls behind pool/startup contention — the
classic "first `fn_task_*` call is slow or errors" experience.
Pre-populating from the already-running engines removes that lazy
worst-case path entirely.

## Verification

- `pnpm verify:fast` — PASS (13 steps, 115s): CLI `tsup` build green,
scoped typecheck/build green, boot smoke green (`fn --help` + real
`serve` with `GET /api/health` 200).
- Cherry-picked cleanly onto current `origin/main` (`5532019fd`); branch
is up-to-date with `origin/main` at PR time.

## Files

- `packages/cli/src/commands/dashboard.ts` (+30)
- `.changeset/extension-host-store-warmup.md` (new)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved dashboard startup reliability by reusing existing project
task connections.
* Prevented extension task tools from creating duplicate connection
pools.
* Added non-blocking warnings when individual project initialization or
discovery fails.
* Dashboard startup now reports how many project task stores were
successfully prepared.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Co-authored-by: gsxdsm <gsxdsm@users.noreply.github.com>
2026-08-07 00:25:39 -07:00
gsxdsm
de38ead4c9 fix(ci): restore main full-suite after path peel and suite drift (#3334)
## Summary
Restores the non-blocking full suite on `main` after consistent shard
failures (latest red: [run
30982276306](https://github.com/Runfusion/Fusion/actions/runs/30982276306);
all four shards failed on `@fusion/core`, `@fusion/engine`, and
`@fusion/plugin-sdk`).

### Fixes
- **Path / import drift** after code-organization peels: update
static-guard and integration tests to new module locations (`central/`,
`board/`, `execution/`, `merge/`, `worktree/`, `plugins/`, `types/*`
barrels, etc.).
- **Inventory re-pins**:
- SQLite production `DatabaseSync` allowlist
(`central/project-identity.ts`, `db/sqlite-validation.ts`)
- Engine blocking-shellout allowlist regenerated from live source (33
audited sites)
  - Core log-severity manifest paths for peeled modules
- **Partial protocol assert update** for `isPlanReviewSatisfied` (file
also quarantined until full rescue)

### Quarantine (deletion ratchet)
Remaining behavioral reds quarantined on sight — no
timeout/retry/assertion appeasement:
- **14 core** files (incomplete unit fakes for `layer.db.select`,
ledger/census drift, 15s wedge timeout, serialization protocol drift)
- **13 engine** files (mock-hoist errors, fake-store/census/behavior
drift under suite)

Paired updates: `scripts/lib/test-quarantine.json` + package vitest
excludes. Deletion clock starts `2026-08-05`.

### Local verification
- Path-fixed core scanners: 173 passed
- Path-fixed engine scanners: 58 passed
- `@fusion/plugin-sdk` full: 16 passed
- PG smokes: mission-autopilot, research-execution, satellite,
transition-pending, workflow-sync

## Test plan
- [ ] CI PR checks green (lint/typecheck/build/gate)
- [ ] Full suite on merge to main: all 4 shards green or only
intentional non-blocking signal
- [ ] Confirm quarantined files appear in ledger + vitest excludes and
are not executed

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Tests**
* Updated test coverage to reflect reorganized source locations and
module paths.
* Refreshed static checks, allowlists, and source-based assertions
without changing tested behavior.
* **Chores**
* Quarantined failing core and engine test suites with documented
tracking details.
* Updated test configuration and quarantine records to improve suite
stability and reporting.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-08-07 00:25:10 -07:00
gsxdsm
8eb050ed49 fix(FN-8764): clear stale planning state after refresh
Fusion-Task-Id: FN-8764
2026-08-06 23:49:37 -07:00
gsxdsm
5e718544ac fix(FN-8806): wire fixture task lane flags 2026-08-06 22:07:23 -07:00
gsxdsm
297ec17f8e FN-8819: preserve useful Planning Mode choices
Planning Mode preserves useful model-provided alternatives while retaining one Other response.

- Preserve distinct choices beyond the preferred 3–5 range
- Deduplicate model-authored Other entries into the canonical free-text choice
- Cover desktop and mobile option selection flows and document the behavior

Files changed:
 .changeset/fn-8819-planning-options.md             |   7 ++
 docs/dashboard-guide.md                            |   3 +-
 .../PlanningModeModal.ui-interactions.test.tsx     | 137 ++++++++++++++++++++-
 .../__tests__/planning-infinite-interview.test.ts  |  28 +++--
 .../planning-interview-formatters.test.ts          |   5 +
 packages/dashboard/src/planning.ts                 |  44 ++++---
 6 files changed, 192 insertions(+), 32 deletions(-)

Fusion-Task-Id: FN-8819

Fusion-Task-Lineage: f748f4b7-3865-4a97-a8b0-d614e0b4cc0a

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-06 20:42:30 -07:00
gsxdsm
6fd49f78c8 FN-8820: contain mobile message structure picker
Keep long structure selections within the shared Messages composer on narrow layouts.

- Make structure picker controls shrinkable and full-width in mobile stacks.
- Cover long-label attachment behavior and shared full-page/modal callers.
- Add a patch changeset for the mobile containment fix.

Files changed:
 .../fn-8820-message-composer-mobile-width.md       |  7 +++++
 .../dashboard/app/components/MessageComposer.css   | 17 +++++++++++
 .../__tests__/MessageComposer.mobile-width.test.ts | 34 ++++++++++++++++++++++
 .../components/__tests__/MessageComposer.test.tsx  | 14 +++++++++
 4 files changed, 72 insertions(+)

Fusion-Task-Id: FN-8820

Fusion-Task-Lineage: a66d51a6-6d92-4402-938c-698c09177583

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-06 20:36:31 -07:00
gsxdsm
cc97970b1d test: use fast user-event instance in SettingsModal CLI-binary tests
Align SettingsModal.cliBinaryVisibility.test.tsx with the harness's
documented fast user-event options ({ delay: null, pointerEventsCheck: 0 },
FN-6612 velocity convention). Removes default inter-keystroke delay and
pointer-events tree walks; file test-time dropped ~1.9s -> ~0.5s.
2026-08-06 17:06:37 -07:00
gsxdsm
c3f4af67d6 FN-8818: enforce planning response choices
Ensure Planning Mode always presents four distinct suggested responses and one Other choice.

- Normalize model and restored awaiting-input questions with localized fallback options
- Deduplicate rendered options and cover restored-session and UI selection behavior
- Document the response-choice contract and add a patch changeset

Files changed:
 .changeset/fn-8818-planning-response-choices.md    |   7 +
 docs/dashboard-guide.md                            |   2 +-
 .../dashboard/app/components/PlanningModeModal.tsx |  39 ++--
 .../PlanningModeModal.ui-interactions.test.tsx     |  37 +++-
 .../planning-answered-question-reemit.test.ts      |  11 +-
 .../__tests__/planning-infinite-interview.test.ts  |  59 +++++-
 packages/dashboard/src/planning.ts                 | 205 +++++++++++++++++----
 7 files changed, 298 insertions(+), 62 deletions(-)

Fusion-Task-Id: FN-8818

Fusion-Task-Lineage: d515c293-c5ab-437b-86c9-734207321ded

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-06 16:19:33 -07:00
gsxdsm
6bacfd74f5 fix(FN-8817): stop no-op lifecycle bounce
Honor verified intentional no-ops and preserve durable merger parks during workflow graph unwind.

Fusion-Task-Id: FN-8817
2026-08-06 16:11:05 -07:00
gsxdsm
5532019fd3 FN-8816: make planning storage failures non-fatal
Keep Planning Mode running when browser storage writes fail.

- Retry failed project-scoped planning persistence after targeted eviction.
- Cover storage failure recovery and planning draft hand-off behavior.
- Quarantine the recurring planning-flow flake and add a patch changeset.

Files changed:
 .changeset/fn-8816-planning-storage-recovery.md    |   7 +
 .../app/hooks/__tests__/modalPersistence.test.ts   | 159 ++++++++++++++++++++-
 packages/dashboard/app/hooks/modalPersistence.ts   |  22 ++-
 packages/dashboard/vitest.config.ts                |   5 +
 scripts/lib/test-quarantine.json                   |   5 +
 5 files changed, 195 insertions(+), 3 deletions(-)

Fusion-Task-Id: FN-8816
Fusion-Task-Lineage: 929c3d96-3a28-49fa-8018-710fc75e3fcc
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-06 08:43:59 -07:00
gsxdsm
3ed31e9907 FN-8815: retry execution after first tool failure
Retry executor work after the first terminal tool-call failure by default.

- Set the default tool-failure threshold to one while preserving explicit project overrides.
- Expose and document the first-error default in Settings, translations, and the settings reference.
- Cover threshold resolution, save lifecycle, and executor retry behavior.

Files changed: .changeset/fn-8815-retry-first-tool-failure.md     |  7 +++
 docs/settings-reference.md                         |  4 +-
 .../core/src/__tests__/settings-defaults.test.ts   |  6 +-
 packages/core/src/config/settings-schema.ts        | 10 ++-
 packages/core/src/tasks/in-review-stall.ts         | 15 ++++-
 packages/core/src/types/settings/settings-scope.ts | 10 ++-
 .../dashboard/app/components/SettingsModal.tsx     |  7 ++-
 .../SettingsModal.scheduling-merge.test.tsx        | 61 +++++++++++++++++-
 .../settings/sections/SchedulingSection.search.ts  |  2 +-
 .../settings/sections/SchedulingSection.tsx        |  4 +-
 .../settings-default-descriptions.test.tsx         | 12 ++++
 .../__tests__/executor-tool-failure-retry.test.ts  | 73 +++++++++++++++++++---
 packages/i18n/locales/en/app.json                  |  2 +-
 packages/i18n/src/resources.d.ts                   | 17 +++--
 14 files changed, 200 insertions(+), 30 deletions(-)

Fusion-Task-Id: FN-8815

Fusion-Task-Lineage: 909181e7-2da5-4a27-92ee-4182732d9695

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-06 08:35:36 -07:00
gsxdsm
001bd2b97a FN-8814: prevent stale planning badges during code review
Keep planning and review lifecycle badges unambiguous across board and list views.

- Classify active non-planning optional review gates for badge precedence.
- Suppress stale Planning badges and empty list placeholders during Code Review.
- Cover card, desktop list, mobile list, and workflow helper badge states.

Files changed:
 packages/dashboard/app/components/ListView.tsx     | 32 ++++++--
 packages/dashboard/app/components/TaskCard.tsx     | 24 +++++-
 .../app/components/__tests__/ListView.test.tsx     | 56 +++++++++++++
 .../app/components/__tests__/TaskCard.test.tsx     | 66 +++++++++++++++
 .../app/utils/__tests__/taskProgress.test.ts       | 96 +++++++++++++++++++++-
 packages/dashboard/app/utils/taskProgress.ts       | 34 ++++++--
 6 files changed, 292 insertions(+), 16 deletions(-)

Fusion-Task-Id: FN-8814

Fusion-Task-Lineage: d3a9f087-02ea-4657-aa9e-30a537458cb9

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-06 08:11:22 -07:00
gsxdsm
64413f4e8d chore(release): v0.75.1
Version bump via changesets.
2026-08-06 00:18:07 -07:00
gsxdsm
cb500eeb4c chore(release): v0.75.1-beta.2
Version bump via changesets.
2026-08-05 18:19:27 -07:00
gsxdsm
4f4aef7173 FN-8811: preserve explicit shared-member review holds
Keep shared branch-group integration moving unless an operator explicitly holds the task.

- Track auto-merge provenance and distinguish explicit user holds from inherited mission policy.
- Preserve manual holds across workflow recovery, merge coordination, API updates, and dashboard status.
- Add regression coverage, document the behavior, and quarantine the observed flaky test.

Files changed:
 .changeset/fn-8811-shared-member-review-hold.md    |   7 ++
 docs/architecture.md                               |   4 +-
 docs/dashboard-guide.md                            |   1 +
 .../mission-store.sync-auto-merge.test.ts          |   7 +-
 .../__tests__/postgres/mission-store.pg.test.ts    |   1 +
 .../__tests__/postgres/store-movement.pg.test.ts   |  20 ++++
 packages/core/src/__tests__/task-merge.test.ts     |  14 +++
 .../core/src/async-stores/async-mission-store.ts   |   6 +-
 packages/core/src/index.gate.ts                    |   1 +
 packages/core/src/index.ts                         |   1 +
 packages/core/src/merge/task-merge.ts              |  20 +++-
 packages/core/src/missions/mission-store.ts        |   6 +-
 packages/core/src/task-store/serialization.ts      |   2 +-
 packages/core/src/task-store/task-creation.ts      |   8 +-
 packages/core/src/types/task/task-core.ts          |  12 ++-
 .../components/__tests__/TaskDetailModal.test.tsx  |  63 ++++++++++++
 .../dashboard/src/__tests__/routes-tasks.test.ts   |  47 +++++++++
 .../src/routes/register-task-workflow-routes.ts    |  15 ++-
 ...cutor-live-branch-group-auto-merge-hold.test.ts |  87 +++++++++++++++++
 .../src/__tests__/group-merge-coordinator.test.ts  |  99 ++++++++++++++++++-
 .../engine/src/__tests__/project-engine.test.ts    |  57 ++++++++++-
 .../self-healing-paused-abort-recovery.test.ts     |  52 +++++++++-
 packages/engine/src/__tests__/self-healing.test.ts | 106 +++++++++++++++++++++
 .../workflow-graph-executor-handlers.test.ts       |  23 +++++
 packages/engine/src/executor.ts                    |  37 ++++++-
 packages/engine/src/project-engine.ts              |  25 +++--
 packages/engine/src/self-healing.ts                |  71 ++++++++++++--
 .../src/workflow-node-runners/merge-runner.ts      |  24 ++++-
 .../src/workflows/workflow-graph-executor.ts       |   4 +
 .../src/workflows/workflow-graph-task-runner.ts    |   6 ++
 .../engine/src/workflows/workflow-node-handlers.ts |   5 +-
 packages/engine/vitest.config.ts                   |  11 ++-
 scripts/lib/test-quarantine.json                   |   5 +
 33 files changed, 789 insertions(+), 58 deletions(-)

Fusion-Task-Id: FN-8811

Fusion-Task-Lineage: 5c1609bf-3132-4988-a254-fedec6c0e33d

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 17:39:15 -07:00
gsxdsm
1e4c7faf68 FN-8812: fix workspace merge retry timer cleanup
Ensure workspace contention retries are canceled when the project engine stops.

- Track workspace busy re-enqueue timers separately from other merge timers
- Clear pending workspace retry callbacks during engine shutdown
- Strengthen retry ladder and timer cleanup coverage

Files changed:
 .changeset/workspace-busy-timer-cleanup.md         |  7 +++
 .../engine/src/__tests__/project-engine.test.ts    | 66 +++++++++++-----------
 packages/engine/src/project-engine.ts              | 23 +++++++-
 3 files changed, 59 insertions(+), 37 deletions(-)

Fusion-Task-Id: FN-8812

Fusion-Task-Lineage: dd4c9581-8738-4082-8d6b-d91d4c463a5a

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 17:10:55 -07:00
gsxdsm
1db7adcdb0 FN-8809: preserve agent principals for secret approvals
Keep prompt-gated secret approvals bound to their calling chat-agent session.

- Resolve extension secret callers through async session identity context.
- Give anonymous engine sessions unique principals and preserve them across tool invocations.
- Surface actionable approval decision errors in the mailbox and cover approval flows.

Files changed:
 .changeset/fn-8809-secrets-chat-approval.md        |   7 +
 .../__tests__/extension-permission-gates.test.ts   | 257 ++++++++++++++++++++-
 packages/cli/src/extension.ts                      |  96 +++++---
 .../__tests__/session-identity-registry.test.ts    |  27 +++
 packages/core/src/index.ts                         |   4 +-
 packages/core/src/session-identity-registry.ts     |  47 +++-
 packages/dashboard/app/components/MailboxView.tsx  |  11 +-
 .../app/components/__tests__/MailboxView.test.tsx  |  49 ++++
 .../dashboard/src/__tests__/chat-manager.test.ts   |  28 ++-
 .../__tests__/register-approval-routes.test.ts     |  22 ++
 .../src/__tests__/pi-create-fn-agent.test.ts       | 210 ++++++++++++++++-
 packages/engine/src/pi.ts                          |  34 ++-
 12 files changed, 748 insertions(+), 44 deletions(-)

Fusion-Task-Id: FN-8809

Fusion-Task-Lineage: 2e070f78-7215-4401-bcf2-6fa25fa27066

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 16:46:53 -07:00
gsxdsm
00fdbe1bef FN-8808: bind dashboard secrets to selected project
Bind dashboard secret operations to the explicitly selected project.

- Include project identity in secrets and sync-passphrase requests.
- Reject missing project IDs before fallback project-store resolution.
- Prevent stale cross-project UI responses and document recovery guidance.

Files changed:
 .changeset/fn-8808-secrets-project-binding.md      |   7 +
 docs/secrets.md                                    |   6 +
 packages/dashboard/app/components/SecretsView.tsx  | 134 ++++++++++++++-----
 .../dashboard/app/components/SettingsModal.tsx     |   2 +-
 .../__tests__/SecretsView.mobile.test.tsx          |   9 ++
 .../app/components/__tests__/SecretsView.test.tsx  | 137 ++++++++++++++++++++
 .../__tests__/SettingsModal.mcp.test.tsx           |  69 +++++++++-
 .../__tests__/SettingsModal.test-harness.tsx       |   8 +-
 .../app/components/dashboard/MainContent.tsx       |   2 +-
 .../app/components/overflowViewRegistry.tsx        |   2 +-
 .../settings/sections/McpServersCard.tsx           |  58 +++++++--
 .../settings/sections/SecretsSection.tsx           |   5 +-
 .../__tests__/register-secrets-routes.test.ts      | 142 +++++++++++++++++++--
 .../src/routes/register-secrets-routes.ts          |  53 +++++---
 14 files changed, 551 insertions(+), 83 deletions(-)

Fusion-Task-Id: FN-8808

Fusion-Task-Lineage: dd224dbe-46a5-49a6-b6e9-5d5bbe4e742e

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 15:41:56 -07:00
gsxdsm
2a0827835d FN-8810: wire secrets stores into runtime worktrees
Wire project secrets stores into runtime and dashboard heartbeat worktree acquisition.

- Inject the project secrets store into executor and heartbeat monitors.
- Cover in-process, UI-only dashboard, and secrets-env worktree materialization paths.
- Add a patch changeset for restored secrets-env files.

Files changed:
 .changeset/fn-8810-secrets-env-runtime-wiring.md   |   7 ++
 .../commands/__tests__/dashboard-supervise.test.ts |  28 ++++-
 packages/cli/src/commands/dashboard.ts             |  38 ++++++-
 .../src/__tests__/in-process-runtime.pg.test.ts    | 121 ++++++++++++++++++++-
 .../src/__tests__/secrets-env-writer.test.ts       |  35 ++++++
 .../worktree-acquisition-secrets-env.test.ts       |   4 +-
 packages/engine/src/runtimes/in-process-runtime.ts |   9 ++
 7 files changed, 233 insertions(+), 9 deletions(-)

Fusion-Task-Id: FN-8810

Fusion-Task-Lineage: a67c3fbe-7744-4898-8a56-8739caa04479

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 15:23:08 -07:00
gsxdsm
6ccde2b0d8 FN-8806: stabilize task title expansion during resize
Keep expanded task titles stable while their container resizes.

- Measure persistent title text separately from the interactive expansion control.
- Fence hidden pop-out resize observers and preserve expansion state across detail hosts.
- Add rendering and browser coverage for resize-driven title behavior.

Files changed:
 .changeset/fn-8806-task-title-flicker.md           |   7 +
 .../dashboard/app/components/TaskDetailModal.css   |  16 +-
 .../dashboard/app/components/TaskDetailModal.tsx   |  37 +--
 .../__tests__/TaskDetailModal.rendering.test.tsx   |  42 +++-
 .../app/task-modal-touch-resize-e2e-fixture.tsx    | 149 +++++++++++-
 .../task-modal-touch-resize-browser.test.ts        | 267 ++++++++++++++++++++-
 6 files changed, 485 insertions(+), 33 deletions(-)

Fusion-Task-Id: FN-8806

Fusion-Task-Lineage: 9519a5dc-ae6d-43e1-a0da-7ac963f27d7f

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 13:02:48 -07:00
gsxdsm
09e4808d7e FN-8807: revalidate dashboard cards after browser resume
Refresh dashboard task data when browser resume signals arrive, while retaining live SSE mutations across delayed snapshots and cache remounts.

- Revalidate on focus, pageshow, visibility, and SSE reconnect with overlapping-request deduplication.
- Reconcile live task creates and deletes synchronously before caching or pruning mutation fences.
- Cover resume triggers, instrumentation, and cache/remount membership races.

Files changed:
 .../fn-8807-dashboard-resume-revalidation.md       |   7 +
 .../useTasks.resume-instrumentation.test.ts        |  41 +++++
 .../dashboard/app/hooks/__tests__/useTasks.test.ts |  65 ++++++++
 packages/dashboard/app/hooks/useTasks.ts           | 185 +++++++++++++++------
 .../dashboard/app/utils/resumeInstrumentation.ts   |   6 +
 5 files changed, 256 insertions(+), 48 deletions(-)

Fusion-Task-Id: FN-8807

Fusion-Task-Lineage: df8f097e-5067-4fcc-8023-92a2ea329b40

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 11:39:23 -07:00
gsxdsm
4324762d9a FN-8805: preserve expanded task titles on resize
Keep task-detail title expansion stable across resize observers and task changes.

- Measure overflow only in the collapsed title layout.
- Preserve explicit expand/collapse selection through stale resize callbacks.
- Cover modal and embedded narrow-title behavior with regression tests.
- Add a patch changeset for the title stability fix.

Files changed:
 .changeset/fn-8805-stable-task-title.md            |   7 ++
 packages/dashboard/app/components/TaskDetailModal.tsx |  39 +++++---
 packages/dashboard/app/components/__tests__/TaskDetailModal.rendering.test.tsx | 110 +++++++++++++++++++++
 3 files changed, 141 insertions(+), 15 deletions(-)

Fusion-Task-Id: FN-8805

Fusion-Task-Lineage: 66177622-78e8-4378-88f6-c0979a96afd2

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 09:58:45 -07:00
gsxdsm
8120c07b6a FN-8804: fix TaskDetailModal optimistic status assertions
Scope optimistic-opening runtime-status assertions to the execution statistics panel.

- Add a helper that verifies the scoped runtime row and lifecycle badge.
- Preserve coverage for duplicate Stats panels without ambiguous DOM queries.

Files changed:
 .../__tests__/TaskDetailModal.rendering.test.tsx   | 23 +++++++++++++++++++---
 1 file changed, 20 insertions(+), 3 deletions(-)

Fusion-Task-Id: FN-8804

Fusion-Task-Lineage: b5573222-5d74-462a-b428-6eca687d68f3

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 01:01:32 -07:00
gsxdsm
907c051844 FN-8803: fix TaskDetailModal prompt refresh coverage
Align TaskDetailModal refresh tests with the narrow prompt API.

- Exercise visible plan refreshes through fetchTaskPrompt
- Reset prompt and detail API mocks to preserve Promise contracts

Files changed:
 .../TaskDetailModal.definition-actions.test.tsx    | 57 +++++++++++++---------
 .../__tests__/TaskDetailModal.test-helpers.ts      | 19 +++++---
 2 files changed, 47 insertions(+), 29 deletions(-)

Fusion-Task-Id: FN-8803

Fusion-Task-Lineage: e2539c24-377b-48bf-81d1-80206da7071c

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 00:55:15 -07:00
gsxdsm
fef3a6daf7 FN-8802: contain task cards in narrow layouts
Keep task-card content within its host at narrow desktop and mobile widths.

- Make task-card roots shrinkable, border-box flex items with bounded width
- Cover minimal and populated narrow-card layouts, including badges and controls

Files changed:
 packages/dashboard/app/components/TaskCard.css     |  7 ++++
 .../__tests__/TaskCard.badge-wrap.test.tsx         | 39 ++++++++++++++++++++++
 2 files changed, 46 insertions(+)

Fusion-Task-Id: FN-8802

Fusion-Task-Lineage: 9b0d58ce-4c48-4f3a-89fc-2ef3d603b47e

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 00:48:47 -07:00
gsxdsm
59cfa47b1c FN-8801: refresh task state after lifecycle actions
Refresh dashboard task views immediately when lifecycle mutations are confirmed.

- Centralize confirmed task reconciliation across pause and unpause actions
- Propagate lifecycle handlers through dashboard detail and dock hosts
- Add state synchronization regression coverage and a patch changeset

Files changed:
 .changeset/fn-8801-immediate-unpause-state.md      |  7 ++
 packages/dashboard/app/App.tsx                     |  6 +-
 packages/dashboard/app/components/AppModals.tsx    |  4 ++
 packages/dashboard/app/components/ListView.tsx     |  2 +
 .../dashboard/app/components/TaskDetailModal.tsx   | 26 +++++---
 .../TaskDetailModal.definition-actions.test.tsx    | 76 +++++++++++++++------
 .../app/components/dashboard/MainContent.tsx       |  2 +
 .../app/components/useRightDockController.tsx      |  4 ++
 .../dashboard/app/hooks/__tests__/useTasks.test.ts | 57 ++++++++++++++++
 packages/dashboard/app/hooks/useTasks.ts           | 77 +++++++++-------------
 10 files changed, 183 insertions(+), 78 deletions(-)

Fusion-Task-Id: FN-8801
Fusion-Task-Lineage: 2ab80d4d-8914-43c5-8ebb-281d31276b61
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 00:34:06 -07:00
gsxdsm
68e964383f chore(release): v0.75.1-beta.1
Version bump via changesets.
2026-08-05 00:12:09 -07:00
gsxdsm
2dcb072472 fix(FN-8795): mark structured findings release as patch 2026-08-05 00:09:42 -07:00
gsxdsm
ec10411c4c FN-8795: persist structured workflow review findings
Persist normalized actionable findings from review workflow nodes.

- Normalize bounded finding IDs, text, locations, and severities in workflow results.
- Surface individual findings for Review-tab selection and same-task revision.
- Preserve findings through workflow retries and document the advisory contract.

Files changed:
 .changeset/fn-8795-structured-review-findings.md   |  7 +++
 docs/dashboard-guide.md                            |  2 +-
 docs/workflow-steps.md                             |  4 +-
 .../src/__tests__/workflow-step-results.test.ts    | 32 +++++++++++++-
 packages/core/src/index.gate.ts                    |  4 ++
 packages/core/src/index.ts                         |  6 ++-
 packages/core/src/types.ts                         |  4 ++
 packages/core/src/types/task/task-review.ts        |  5 +++
 packages/core/src/types/workflow/workflow-steps.ts | 20 +++++++++
 .../core/src/workflows/workflow-step-results.ts    | 50 +++++++++++++++++++++-
 .../dashboard/app/components/TaskReviewTab.tsx     | 12 +++++-
 .../src/routes/register-task-workflow-routes.ts    | 26 ++++++++++-
 .../workflow-malformed-verdict-gate.test.ts        | 12 ++++++
 packages/engine/src/executor.ts                    | 46 +++++++++++++++++---
 .../src/workflows/workflow-graph-executor.ts       | 11 +++++
 15 files changed, 227 insertions(+), 14 deletions(-)

Fusion-Task-Id: FN-8795
Fusion-Task-Lineage: 09003b01-3f9a-4387-b6a7-f29066ce52f6
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-05 00:00:03 -07:00
gsxdsm
bfd9c9c86e fix(FN-8794): mark review-kind release as patch 2026-08-04 23:53:36 -07:00
gsxdsm
9c77788850 fix(FN-8795): refresh queued overlap blockers 2026-08-04 23:42:06 -07:00
gsxdsm
e75c788db2 FN-8794: add workflow review-kind markers
Classify workflow review nodes so review feedback can target their persisted results.

- validate and type explicit plan/code review-kind markers in workflow IR
- expose review-kind selection in the workflow editor and document the authoring contract
- persist markers through task workflow routes and graph execution with regression coverage

Files changed:
 .changeset/fn-8794-review-kind.md                  |   7 +
 docs/dashboard-guide.md                            |   4 +
 docs/workflow-steps.md                             |  10 +
 .../__tests__/workflow-ir-optional-group.test.ts   |  17 ++
 packages/core/src/__tests__/workflow-ir.test.ts    |  83 +++++++++
 packages/core/src/index.gate.ts                    |   2 +-
 packages/core/src/index.ts                         |   2 +-
 packages/core/src/types.ts                         |   2 +
 packages/core/src/types/workflow/workflow-steps.ts |   8 +
 .../src/workflows/builtin-code-review-group.ts     |   1 +
 .../src/workflows/builtin-plan-review-group.ts     |   1 +
 packages/core/src/workflows/workflow-ir-types.ts   |   5 +
 packages/core/src/workflows/workflow-ir.ts         |  24 +++
 .../app/components/WorkflowNodeEditor.tsx          |  17 ++
 .../__tests__/WorkflowNodeEditor.test.tsx          | 206 +++++++++++++++++++++
 .../dashboard/src/__tests__/routes-tasks.test.ts   | 166 ++++++++++++++++-
 .../src/routes/register-task-workflow-routes.ts    |  82 ++++++--
 .../workflow-graph-optional-group.test.ts          | 177 +++++++++++++++++-
 .../src/workflows/workflow-graph-executor.ts       |  20 +-
 19 files changed, 801 insertions(+), 33 deletions(-)

Fusion-Task-Id: FN-8794

Fusion-Task-Lineage: a7752469-59bc-406f-82e8-6ffde6c392ef

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-04 23:36:32 -07:00
gsxdsm
6f939a08a0 FN-8800: update board badges promptly
Accept authoritative equal-clock move events so board badges reflect lifecycle transitions without waiting for refresh.

- Treat canonical task:moved SSE destinations as authoritative when lifecycle clocks tie.
- Preserve rejection of delayed older move events.
- Cover prompt badge updates and stale-event protection in useTasks tests.

Files changed:
 .../dashboard/app/hooks/__tests__/useTasks.test.ts | 49 ++++++++++++++++++++++
 packages/dashboard/app/hooks/useTasks.ts           | 13 +++++-
 2 files changed, 61 insertions(+), 1 deletion(-)

Fusion-Task-Id: FN-8800

Fusion-Task-Lineage: 2982c053-bdfb-40d6-9e92-29a429a2a7e6

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-04 22:36:19 -07:00
gsxdsm
35810666be FN-8797: stabilize task detail refreshes
Keep task-detail state and controls mounted while Definition content refreshes.

- Add a prompt-only task endpoint and client request path.
- Preserve task lifecycle, workflow badges, and actions during prompt refreshes and workflow updates.
- Cover prompt refresh stability, late responses, and route behavior.

Files changed:
 packages/dashboard/app/__tests__/api-tasks.test.ts |  14 ++
 packages/dashboard/app/api/legacy.ts               |   3 +
 packages/dashboard/app/api/tasks/tasks.ts          |  15 ++
 .../dashboard/app/components/TaskDetailModal.tsx   | 102 ++++++----
 .../__tests__/TaskDetailModal.rendering.test.tsx   | 211 ++++++++++++++++++---
 .../__tests__/TaskDetailModal.test-helpers.ts      |   1 +
 ...gister-task-workflow-routes.task-prompt.test.ts |  93 +++++++++
 .../src/routes/register-task-workflow-routes.ts    |  17 ++
 8 files changed, 388 insertions(+), 68 deletions(-)

Fusion-Task-Id: FN-8797

Fusion-Task-Lineage: 57d571b4-4a02-4c96-9986-444c525d8405

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-04 22:22:41 -07:00
gsxdsm
26219b8d34 FN-8799: suppress alerts during automatic task recovery
Prevent terminal task alerts while persisted automatic recovery owns a failed task.

- Classify scheduled and transient merge recovery ownership before wedge notification claims.
- Re-read live task state before claims and deferred failure delivery to avoid recovery races.
- Add recovery suppression coverage, architecture documentation, and a patch changeset.

Files changed:
 .changeset/fn-8799-recovery-notifications.md       |  7 ++
 docs/architecture.md                               |  2 +
 .../src/errors/transient-merge-error-classifier.ts | 18 +++++
 .../__tests__/notification-service.test.ts         | 78 ++++++++++++++++++-
 .../__tests__/task-wedge-notification.test.ts      | 26 ++++++-
 .../src/notification/notification-service.ts       | 90 ++++++++++++----------
 .../src/notification/task-wedge-notification.ts    | 37 +++++++--
 packages/engine/src/project-engine.ts              |  4 +-
 8 files changed, 210 insertions(+), 52 deletions(-)

Fusion-Task-Id: FN-8799

Fusion-Task-Lineage: f8296e81-6b84-4697-8b20-63823f09d584

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-04 22:17:06 -07:00
Phil Larson
3071018593 fix: prepare browser smoke fixture before launch (#3333)
## Summary
- prepares emitted dashboard CSS and binds the fixture server before
starting Chrome
- prevents cold client builds from consuming the supervised browser
lifetime
- adds a regression that holds browser launch until fixture preparation
resolves

## Test plan
- `FUSION_DASHBOARD_DEEP=1 pnpm --filter @fusion/dashboard exec vitest
run --project dashboard-app-quality-foundation-ui --pool=vmThreads
--maxWorkers=1 --silent=passed-only --reporter=dot
app/__tests__/browser-layout-smoke-fixture.test.ts`
- `pnpm --filter @fusion/dashboard typecheck`
- `pnpm --filter @fusion/dashboard build`
- `FUSION_BROWSER_SMOKE_REQUIRE=1 pnpm --filter @fusion/dashboard
test:browser-smoke`
- `pnpm exec eslint packages/dashboard/scripts/browser-layout-smoke.mjs
packages/dashboard/app/__tests__/browser-layout-smoke-fixture.test.ts`

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Bug Fixes**
* Improved browser smoke test setup to ensure fixture preparation
completes before the browser launches.
* Added cleanup handling when browser startup fails, preventing leftover
test resources.
* Preserved the primary browser launch error when cleanup also fails,
while recording the cleanup issue.

* **Tests**
* Added coverage for fixture startup order, launch failures, and cleanup
behavior.
  * Preserved existing HTML fixture validation.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-08-04 22:03:52 -07:00
gsxdsm
fa3df0f6bd FN-8798: synchronize planning status across task views
Keep board, list, and task detail planning indicators consistent with fresh lifecycle state.

- preserve authoritative task snapshots across SSE and detail refreshes
- render transient replan planning only for fresh, unpaused planner activity
- pass global pause state to every task-detail host and cover status convergence

Files changed:
 packages/dashboard/app/App.tsx                     |   2 +
 packages/dashboard/app/components/AppModals.tsx    |   3 +
 packages/dashboard/app/components/ListView.tsx     |  11 +-
 packages/dashboard/app/components/TaskCard.tsx     |   7 +-
 .../dashboard/app/components/TaskDetailModal.tsx   |  27 ++-
 .../app/components/__tests__/AppModals.test.tsx    | 201 +++++++++++++++++++--
 .../app/components/__tests__/ListView.test.tsx     |  31 ++++
 .../app/components/__tests__/TaskCard.test.tsx     |  17 ++
 .../app/components/dashboard/MainContent.tsx       |   1 +
 .../__tests__/useTasks-hydration-freshness.test.ts |  58 +++++-
 .../dashboard/app/hooks/__tests__/useTasks.test.ts |  29 ++-
 packages/dashboard/app/hooks/useTasks.ts           |  51 +++++-
 .../utils/__tests__/taskStatusBadgeLabel.test.ts   |  22 ++-
 .../dashboard/app/utils/taskStatusBadgeLabel.ts    |  36 ++++
 14 files changed, 453 insertions(+), 43 deletions(-)

Fusion-Task-Id: FN-8798

Fusion-Task-Lineage: 7defae4e-fb39-4d2c-943a-ef6c1a164bfc

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-04 21:57:00 -07:00
gsxdsm
6a5e1b0145 chore(release): v0.75.1-beta.0
Version bump via changesets.
2026-08-04 20:38:29 -07:00
gsxdsm
1320265455 FN-8796: stabilize task-detail lifecycle snapshots
Keep open task details on their newest lifecycle state during scheduler resyncs.

- Reconcile task snapshots by lifecycle timestamps across modal, panel, dock, list, and popup hosts.
- Preserve fetched detail fields while accepting only fresher status and column transitions.
- Cover stale queued dependency and file-overlap payload regressions.

Files changed:
 packages/dashboard/app/App.tsx                     |   7 +-
 packages/dashboard/app/components/AppModals.tsx    |  16 +---
 packages/dashboard/app/components/ListView.tsx     |   9 +-
 .../dashboard/app/components/TaskDetailModal.tsx   |  33 +++----
 .../app/components/__tests__/AppModals.test.tsx    |  59 ++++++++++++
 .../__tests__/TaskDetailModal.rendering.test.tsx   |  45 +++++++++
 .../app/components/dashboard/MainContent.tsx       |   8 +-
 .../app/components/useRightDockController.tsx      |   4 +-
 .../__tests__/useTasks-hydration-freshness.test.ts |  49 +++++++++-
 packages/dashboard/app/hooks/useModalManager.ts    |   3 +-
 packages/dashboard/app/hooks/useTasks.ts           | 103 +++++++++++++--------
 11 files changed, 252 insertions(+), 84 deletions(-)

Fusion-Task-Id: FN-8796

Fusion-Task-Lineage: 430b2c46-717d-4b83-803f-6574cf64670d

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-04 20:13:45 -07:00
gsxdsm
4167841e3c FN-8792: resume Plan Review after approval
Approved plans now seed their canonical Plan Review continuation so dispatch can proceed.

- Add an engine handoff that atomically seeds approved Plan Review work without duplicating active continuations.
- Invoke the handoff under the dashboard approval lifecycle lock and cover approval, duplicate, and lifecycle-fence cases.
- Document the lifecycle guarantee and add a patch changeset.

Files changed:
 .changeset/fn-8792-plan-approval-dispatch.md       |   7 +
 docs/architecture.md                               |   6 +-
 .../dashboard/src/__tests__/routes-github.test.ts  | 167 ++++++++++++++++++++-
 .../src/routes/register-task-workflow-routes.ts    |  17 +++
 .../__tests__/plan-approval-hold-invariant.test.ts |  70 +++++++++
 packages/engine/src/index.ts                       |   4 +
 packages/engine/src/plan-review-continuation.ts    |  38 +++++
 7 files changed, 304 insertions(+), 5 deletions(-)

Fusion-Task-Id: FN-8792

Fusion-Task-Lineage: 0645c48d-ec92-475d-9e29-73cc22c12df8

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-04 19:31:06 -07:00
gsxdsm
0658795181 FN-8793: restore workflow review feedback selection
Restore canonical workflow review feedback so revisions can select server-owned reviewer items.

- Normalize current Code Review and Plan Review workflow results into stable review items.
- Preserve verdict and reviewer type through review API mappings and reject forged client feedback.
- Add regression coverage and a patch changeset.

Files changed:
 .changeset/fn-8793-workflow-review-items.md        |   7 +
 packages/core/src/index.gate.ts                    |   2 +-
 packages/core/src/index.ts                         |   2 +-
 packages/core/src/types/task/task-review.ts        |   6 +-
 packages/dashboard/app/api/agents/run-audit.ts     |   2 +
 .../dashboard/src/__tests__/routes-tasks.test.ts   | 121 +++++++++++++++++
 .../src/routes/register-task-workflow-routes.ts    | 148 ++++++++++++++++++---
 7 files changed, 264 insertions(+), 24 deletions(-)

Fusion-Task-Id: FN-8793

Fusion-Task-Lineage: 25da04f9-5c30-4ad8-9f82-e1ac91ec481f

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-08-04 19:23:20 -07:00