Commit Graph

10093 Commits

Author SHA1 Message Date
gsxdsm
dbe1e2e39f FN-7093: tighten lazy-view inventory guard
Keep the lazy-loaded views documentation guard aligned with every curated chunk source.

- Expand AGENTS guidance to name the plugin and agent detail lazy-import sources.
- Teach the dashboard docs test to scan feature-owned lazy declarations in PluginsSection and AgentsView.
- Assert explicit exclusions for embedded views, terminal/onboarding internals, and duplicate overflow imports.

Files changed:
 AGENTS.md                                          |   4 +-
 .../app/__tests__/lazy-loaded-views-docs.test.ts   | 113 +++++++++++++++++++--
 2 files changed, 108 insertions(+), 9 deletions(-)

Fusion-Task-Id: FN-7093

Fusion-Task-Lineage: 25bbe920-529d-4f2b-95d4-4c17b682dc49

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-27 09:28:29 -07:00
gsxdsm
b4b9db12a4 test: quarantine 11 failing CI full-suite tests (#1792)
## Summary

Quarantine 11 test files consistently failing on the non-blocking
full-suite CI on `main`. Per the AGENTS.md deletion-ratchet policy, each
is added to `scripts/lib/test-quarantine.json` with a matching exclude
in its package's vitest config.

## Quarantined Tests

| Shard | Package | File | Failure |
|-------|---------|------|---------|
| 1/4 | engine-reliability | `lease-recovery-central-claim.test.ts` |
mock call count mismatch |
| 1/4 | engine-reliability |
`owning-node-unavailable-interactions.test.ts` | mock call count
mismatch |
| 1/4 | engine-reliability | `todo-inprogress-flapping.test.ts` | mock
call count + boolean mismatches |
| 1/4 | engine-default | `ce-workflow-step-conventions.test.ts` |
dual-form CE skill resolution |
| 1/4 | engine-default | `executor-column-agent-principal.test.ts` |
column agent model preservation |
| 1/4 | engine-default | `scheduler-ephemeral-toggle.test.ts` |
assertion failure |
| 2/4 | engine-default | `restart.integration.test.ts` | scheduler mock
call count mismatches |
| 2/4 | engine-default | `scheduler-node-unreachable-audit.test.ts` |
expected undefined to be event type |
| 2/4 | engine-default | `scheduler-overlap-starvation.test.ts` |
assertion failure |
| 2/4 | engine-default | `user-configured-command-no-execsync.test.ts` |
assertion failure |
| 3/4 | cli | `extension.test.ts` | Target cannot be null or undefined |

CI run: https://github.com/Runfusion/Fusion/actions/runs/28259456548

## Verification

- `pnpm test:gate` passes
- `pnpm lint` clean


<!-- stage-review-badge-begin -->

---

<a href="https://stagereview.app/Runfusion/Fusion/pull/1792">
  <picture>
<source media="(prefers-color-scheme: dark)"
srcset="https://stagereview.app/assets/gh-open-in-stage-dark.svg">
<img src="https://stagereview.app/assets/gh-open-in-stage-light.svg"
alt="Open in Stage">
  </picture>
</a>

<!-- stage-review-badge-end -->

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

* **Bug Fixes**
* Updated CI test quarantine settings to exclude newly identified
flaky/failing suites from active runs, reducing noisy failures.
* Expanded the quarantine ledger with recent CLI, engine, and dashboard
test entries and failure context to improve tracking and stability.
* **Tests**
* Adjusted the test runner’s project exclusions so quarantined suites
are skipped during CI while preserving coverage elsewhere.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-06-26 23:40:24 -07:00
gsxdsm
9020f5774e test: quarantine 11 failing CI full-suite tests
Quarantine test files consistently failing on the non-blocking full-suite
CI on main, per the AGENTS.md deletion-ratchet policy:

Engine-default (shard 1-2): ce-workflow-step-conventions,
executor-column-agent-principal, restart.integration,
scheduler-node-unreachable-audit, scheduler-overlap-starvation,
scheduler-ephemeral-toggle, user-configured-command-no-execsync

Engine-reliability (shard 1): lease-recovery-central-claim,
owning-node-unavailable-interactions, todo-inprogress-flapping

CLI (shard 3): extension.test.ts

Each has a matching entry in scripts/lib/test-quarantine.json with the
failing CI run link and quarantinedAt date. Tests will be deleted
after 14 days unless rescued with a root-cause fix.
2026-06-26 21:49:32 -07:00
gsxdsm
ae0679b004 FN-7089: add other answers to interview prompts
Adds free-text Other answers across planning and mission interview prompts.

- Add synthetic Other options for single-select and multi-select planning, mission, milestone, and slice interviews.
- Thread reserved `_other` responses through agent-facing and history formatters.
- Cover Other-only and Other-plus-selection behavior with dashboard component and formatter tests.
- Document the behavior and add a minor changeset for the published CLI package.

Files changed:
 .changeset/fn-7089-interview-other-option.md       |   7 +
 docs/dashboard-guide.md                            |   2 +
 .../components/MilestoneSliceInterviewModal.tsx    | 112 +++++++-
 .../app/components/MissionInterviewModal.tsx       | 112 +++++++-
 .../dashboard/app/components/PlanningModeModal.css |  11 +-
 .../dashboard/app/components/PlanningModeModal.tsx | 110 +++++++-
 .../MilestoneSliceInterviewModal.test.tsx          | 313 +++++++++++++++++++++
 .../__tests__/MissionInterviewModal.test.tsx       | 244 ++++++++++++++++
 .../PlanningModeModal.planning-flow.test.tsx       | 200 +++++++++++++
 .../__tests__/milestone-slice-interview.test.ts    |  49 +++-
 .../src/__tests__/mission-interview.test.ts        |  47 ++++
 .../planning-interview-formatters.test.ts          |  47 ++++
 .../dashboard/src/milestone-slice-interview.ts     |  63 ++++-
 packages/dashboard/src/mission-interview.ts        |  63 ++++-
 packages/dashboard/src/planning.ts                 |  55 ++--
 15 files changed, 1381 insertions(+), 54 deletions(-)

Fusion-Task-Id: FN-7089

Fusion-Task-Lineage: 1c629492-13e4-4ee7-aa37-1d7d067548b7

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-26 21:31:42 -07:00
gsxdsm
513882ecac FN-7087: speed up SettingsModal remote tests
Optimize the SettingsModal remote-notifications shard by rendering target sections directly.

- Add a section-targeted SettingsModal test harness helper.
- Reuse the no-delay shared user event instance across remote-notifications tests.
- Update velocity baseline documentation and history with the faster shard timing.

Files changed:
 docs/test-velocity-baseline.md                     |  72 +++---
 .../SettingsModal.remote-notifications.test.tsx    | 279 ++++++++-------------
 .../__tests__/SettingsModal.test-harness.tsx       |  16 ++
 scripts/test-velocity-history.json                 | 119 +++++++++
 4 files changed, 275 insertions(+), 211 deletions(-)

Fusion-Task-Id: FN-7087

Fusion-Task-Lineage: aec39ac9-dd6a-49b5-96c2-07a8d0a119b7

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-26 19:16:26 -07:00
gsxdsm
cc7917d9a1 FN-7088: index unlinked documentation pages
Document the previously unlinked docs from the README index for easier discovery.

- Add Signals Connectors to the documentation guide section.
- Add testing baseline and audit reports to the audit reports index.
- Record the FN-7088 docs-index requirement in the existing FNXC DocsIndex note.

Files changed:
 docs/README.md | 7 +++++++
 1 file changed, 7 insertions(+)

Fusion-Task-Id: FN-7088

Fusion-Task-Lineage: df77fa9a-ba63-4df9-ac70-d144230eb8f3

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-26 18:53:08 -07:00
gsxdsm
5608bf555f FN-7083: derive project in-flight counts from live tasks
Derive CLI project in-flight agent displays from live in-progress task counts instead of persisted health bookkeeping.

- Add shared CLI display health handling for project list and show output.
- Cover stale, missing, unreadable, table, and JSON project health cases in CLI tests.
- Clarify central health and concurrency fields as persisted bookkeeping in docs and types.
- Add a patch changeset for the published CLI behavior fix.

Files changed:
 .changeset/fn-7083-cli-inflight-live-count.md      |   7 +
 docs/architecture.md                               |   1 +
 docs/multi-project.md                              |   4 +-
 .../cli/src/commands/__tests__/project.test.ts     | 172 ++++++++++++++++++++-
 packages/cli/src/commands/project.ts               |  60 ++++---
 packages/cli/src/project-resolver.ts               |   4 +
 packages/core/src/types.ts                         |  12 +-
 7 files changed, 235 insertions(+), 25 deletions(-)

Fusion-Task-Id: FN-7083

Fusion-Task-Lineage: 2b57cb35-383f-443b-8bf3-3fc3c7a1ad43

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-26 18:35:54 -07:00
gsxdsm
8bcda7325c FN-7082: add live running-agent count seam
Add a side-effect-safe core seam so global concurrency reads can report live running-agent counts.

- Add core helpers to register a running-agent count source and derive active project totals.
- Wire CentralCore and dashboard server setup to read live counts from already-open stores without starting runtimes.
- Update the global concurrency route to preserve slot bookkeeping while sourcing currentlyActive/projectsActive from the live seam.
- Cover the seam, dashboard store resolver, server wiring, and route behavior with focused tests and document the multi-project behavior.

Files changed:
 .changeset/fn-7082-live-running-agent-count-seam.md       |   7 ++
 docs/multi-project.md                              |   2 +-
 packages/core/src/__tests__/central-core.test.ts   | 106 +++++++++++++++++++++
 packages/core/src/central-core.ts                  |  28 ++++++
 packages/core/src/index.ts                         |   7 ++
 packages/core/src/live-agent-count.ts              |  38 ++++++++
 .../dashboard/src/__tests__/project-routes.test.ts |  20 +++-
 .../src/__tests__/project-store-resolver.test.ts   |  71 ++++++++++++++
 packages/dashboard/src/__tests__/server.test.ts    |  45 ++++++++-
 packages/dashboard/src/project-store-resolver.ts   |  24 +++++
 packages/dashboard/src/routes.ts                   |  25 +----
 packages/dashboard/src/server.ts                   |  42 +++++++-
 12 files changed, 387 insertions(+), 28 deletions(-)

Fusion-Task-Id: FN-7082

Fusion-Task-Lineage: 4dbca204-8bea-4de5-b56b-7468b61575ce

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-26 18:19:41 -07:00
gsxdsm
d9b17dea01 FN-7086: default dirty checkout merge sync
Default AI merge landing to preserve legacy dirty-checkout synchronization for new and partially configured projects.

- Default resolved project merger settings to allow dirty local checkout sync while preserving explicit false values.
- Pass the resolved dirty-checkout sync policy through single-repo and workspace AI merge landing paths.
- Update settings UI defaults, type docs, regression coverage, and release notes for the new behavior.

Files changed:
 .changeset/fn-7086-allow-dirty-sync-default.md     |  7 ++++
 packages/core/src/__tests__/store-settings.test.ts | 40 ++++++++++++++++++++++
 packages/core/src/settings-schema.ts               |  6 +++-
 packages/core/src/store.ts                         | 12 +++++++
 packages/core/src/types.ts                         |  6 ++--
 .../dashboard/app/components/SettingsModal.tsx     |  2 +-
 packages/engine/src/merger-ai.ts                   | 35 +++++++++++--------
 7 files changed, 89 insertions(+), 19 deletions(-)

Fusion-Task-Id: FN-7086
Fusion-Task-Lineage: 65871e7c-af0c-45b9-af54-749d56dfadd5
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-26 18:11:41 -07:00
gsxdsm
0ddfe9a422 FN-7084: add concurrency save confirmations
Require explicit confirmation before Command Center concurrency sliders persist live capacity changes.

- Add confirmation flows for global and project concurrency sliders after debounce settles.
- Revert pending slider values on cancel, Escape, or backdrop dismissal without saving.
- Cover single, batched, no-op, failure, and dismissal paths in Command Center control tests.
- Document the confirmation behavior and add a published package changeset.

Files changed:
 .changeset/FN-7084-concurrency-confirm.md          |   7 +
 docs/dashboard-guide.md                            |   3 +-
 .../command-center/CommandCenterControls.tsx       | 169 ++++++++++++++---
 .../__tests__/CommandCenterControls.test.tsx       | 203 +++++++++++++++++----
 4 files changed, 323 insertions(+), 59 deletions(-)

Fusion-Task-Id: FN-7084

Fusion-Task-Lineage: f1ebe1f7-f570-4bcb-9dad-7c8f03808d54

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-26 18:01:21 -07:00
gsxdsm
42d9c656ee FN-7080: report live concurrency counts
Derive global concurrency running totals from live task columns so active work no longer appears idle.

- Count in-progress tasks across all projects for `/api/global-concurrency`.
- Replace stale slot bookkeeping in the response while preserving configured caps and queue counts.
- Cover empty, multi-project, and over-cap running-count scenarios in route tests.
- Add a patch changeset for the published Fusion package.

Files changed:
 .changeset/fn-7080-concurrency-running-count-fix.md       |   7 ++
 packages/dashboard/src/__tests__/project-routes.test.ts | 113 +++++++++++++++++++++
 packages/dashboard/src/routes.ts                   |  29 +++++-
 3 files changed, 148 insertions(+), 1 deletion(-)

Fusion-Task-Id: FN-7080

Fusion-Task-Lineage: a22d366f-ea93-47a5-b758-5e2d3828cff3

Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-26 17:43:56 -07:00
gsxdsm
4c48ccfe03 FN-7078: forward MCP config to planning helpers
Dashboard readonly planning helpers now receive scoped MCP server configuration when creating AI sessions.

- Thread request-scoped TaskStore access into subtask, text refine, goal drafting, agent onboarding, PR metadata, insight, and triage helper paths.
- Resolve and forward in-memory MCP server declarations while preserving empty no-store fallbacks and secret hygiene.
- Document the expanded MCP forwarding surface and add regression coverage for helper forwarding and retry paths.
- Add a changeset for the published Fusion package.

Files changed:
 .changeset/fn-7078-mcp-planning-helpers.md         |   7 +
 docs/mcp.md                                        |   6 +-
 .../src/__tests__/agent-generation.test.ts         |   3 +
 .../src/__tests__/agent-onboarding.test.ts         |  72 +++++-
 packages/dashboard/src/__tests__/ai-refine.test.ts |  96 +++++++-
 .../src/__tests__/mcp-helper-forwarding.test.ts    | 258 +++++++++++++++++++++
 .../src/__tests__/pr-metadata-generator.test.ts    |   1 +
 .../src/__tests__/subtask-breakdown.test.ts        | 137 ++++++++++-
 packages/dashboard/src/agent-generation.ts         |  17 +-
 packages/dashboard/src/agent-onboarding.ts         |  49 +++-
 packages/dashboard/src/ai-refine.ts                |  18 +-
 packages/dashboard/src/insights-routes.ts          |  40 ++--
 packages/dashboard/src/pr-metadata-generator.ts    |  13 +-
 packages/dashboard/src/routes.ts                   |   3 +-
 ...gister-agent-import-export-generation-routes.ts |   6 +-
 .../dashboard/src/routes/register-git-github.ts    |   1 +
 .../src/routes/register-planning-subtask-routes.ts |   2 +-
 packages/dashboard/src/subtask-breakdown.ts        |  27 ++-
 packages/dashboard/src/triage-trait.ts             |   2 +-
 19 files changed, 695 insertions(+), 63 deletions(-)

Fusion-Task-Id: FN-7078
Fusion-Task-Lineage: 8ed30003-7a27-42e9-8b37-5ceb1a832334
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-06-26 17:38:41 -07:00
gsxdsm
f78711d21e test(FN-5048): replace fixed sleeps with polled waits in ws badge tests
Swap fixed 200ms "wait for pub/sub propagation" sleeps in the
multi-instance badge tests for polled waitForExpectation calls. Returns
on delivery (typically <20ms) instead of always paying 200ms, and
removes the delivery>200ms race an unconditional sleep masks.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 17:33:12 -07:00
gsxdsm
20002e7186 test(FN-7077): allow dual-scoped mcpServers in settings parity guard
mcpServers is intentionally shared across global and project scopes (a
global default applies to every project; a project override tailors the
set per project). Add it to the parity guard's intentional shared-keys
allow-list.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 17:33:11 -07:00
gsxdsm
525953b494 fix: stop schema comments truncating parsed table bodies
parseCreateTableSchemasFromSql now strips `--` comments before the
non-greedy CREATE TABLE body regex, so a `);` inside a schema comment can
no longer end a table body early and silently drop columns from
ensureSchemaCompatibility()'s backfill set. Fixes legacy DBs missing
newer task columns (checkout-lease, column dwell) after upgrade.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 17:33:06 -07:00
gsxdsm
ad3149093a FN-7077: inject configured MCP servers across agent surfaces
Configured MCP servers now follow every agent-work lane that launches model-backed tools.

- Thread MCP server forwarding through chat, task execution, tools, PR response, cron, memory, research, and planning surfaces.
- Add regression coverage for dashboard and engine lanes that previously omitted MCP server configuration.
- Document all covered MCP surfaces and add a published package changeset.

Files changed:
 .changeset/fn-7077-mcp-all-surfaces.md             |   7 +
 docs/mcp.md                                        |   3 +
 docs/settings-reference.md                         |   2 +-
 packages/cli/src/commands/__tests__/serve.test.ts  |   3 +-
 packages/core/src/memory-compaction.ts             |   4 +
 .../src/__tests__/mcp-lane-forwarding.test.ts      |  62 +++++++++
 packages/dashboard/src/agent-generation.ts         |   4 +
 packages/dashboard/src/ai-refine.ts                |   8 ++
 .../dashboard/src/milestone-slice-interview.ts     |  11 +-
 packages/dashboard/src/mission-interview.ts        |   9 +-
 packages/dashboard/src/pr-conflict-resolver.ts     |  12 +-
 packages/dashboard/src/routes.ts                   |  10 ++
 packages/dashboard/src/subtask-breakdown.ts        |   8 ++
 packages/engine/src/__tests__/cron-runner.test.ts  |  61 +++++++++
 .../src/__tests__/mcp-lane-forwarding.test.ts      |   3 +-
 .../__tests__/mcp-pr-response-forwarding.test.ts   | 110 ++++++++++++++++
 .../src/__tests__/mcp-surface-coverage.test.ts     | 141 +++++++++++++++++++++
 packages/engine/src/agent-heartbeat.ts             |  18 +++
 packages/engine/src/cli-agent-ask.ts               |   4 +
 packages/engine/src/cron-runner.ts                 |   9 +-
 packages/engine/src/pr-nodes.ts                    |   2 +-
 packages/engine/src/pr-response-run-ops.ts         |  10 +-
 packages/engine/src/project-engine.ts              |   2 +-
 .../research/providers/llm-synthesis-provider.ts   |   4 +
 .../src/research/providers/web-search-provider.ts  |   4 +
 25 files changed, 497 insertions(+), 14 deletions(-)

Fusion-Task-Id: FN-7077
Fusion-Task-Lineage: 00d36357-c3d8-4954-b647-d3aea24a967b
2026-06-26 16:14:44 -07:00
gsxdsm
af8cc7b29c FN-7079: Correct quarantine baseline reporting
Correct the velocity baseline to reflect an empty quarantine ledger and cover that report-only path.

- Update the published test velocity baseline quarantine totals, buckets, trend row, and #leads summary to zero.
- Add a regression test that regenerates the report from an empty live quarantine ledger without measuring lanes.
- Assert deletion-due and bucket rows stay zero and stale nonzero quarantine text is removed.

Files changed:
 docs/test-velocity-baseline.md                    | 10 ++--
 scripts/__tests__/test-velocity-baseline.test.mjs | 72 ++++++++++++++++++++++-
 2 files changed, 76 insertions(+), 6 deletions(-)

Fusion-Task-Id: FN-7079

Fusion-Task-Lineage: d641adc3-f991-4d95-bcb2-7b20bbfeb0bb
2026-06-26 15:50:40 -07:00
gsxdsm
0440ae4bb9 FN-7074: make task ID reservation commits atomic
Task creation now commits or rolls back distributed task ID reservations with the task-row transaction.

- Add transaction-participating reservation commit and rollback helpers.
- Wire create, duplicate, and refinement task paths to commit reservations inside task insertion.
- Record rollback audit events and preserve burned reservation rows after failed creates.
- Cover atomicity, rollback, and allocator behavior with reservation-focused tests and docs.

Files changed:
 .changeset/fn-7074-reservation-atomicity.md        |   7 +
 AGENTS.md                                          |   1 +
 docs/architecture.md                               |   7 +-
 docs/storage.md                                    |   4 +-
 .../core/src/__tests__/distributed-task-id.test.ts |  25 ++-
 .../__tests__/store-reservation-atomicity.test.ts  | 224 +++++++++++++++++++++
 packages/core/src/distributed-task-id.ts           | 208 +++++++++++++------
 packages/core/src/store.ts                         |  93 +++++++--
 8 files changed, 479 insertions(+), 90 deletions(-)

Fusion-Task-Id: FN-7074

Fusion-Task-Lineage: 464a98cf-e903-4257-93ac-424c7129412b
2026-06-26 14:55:01 -07:00
gsxdsm
93b01c8ea9 FN-7076: show Command Center concurrency utilization
Surface Command Center concurrency utilization beside the editable caps.

- Add loaded-only running-agent readouts for global and current-project concurrency.
- Render clamped current-use markers on the global and project max-concurrent sliders without intercepting drags.
- Cover loaded, zero, unavailable, over-subscribed, and persistence behavior in Command Center tests.
- Document the utilization indicators and add a release changeset.

Files changed:
 .../fn-7076-command-center-concurrency-counts.md   |   7 ++
 docs/dashboard-guide.md                            |   3 +-
 .../command-center/CommandCenterControls.css       |  22 ++++
 .../command-center/CommandCenterControls.tsx       | 103 ++++++++++++++-----
 .../__tests__/CommandCenterControls.test.tsx       | 111 +++++++++++++++++++++
 5 files changed, 219 insertions(+), 27 deletions(-)

Fusion-Task-Id: FN-7076

Fusion-Task-Lineage: 540a57aa-a31b-4a57-aff6-47b373713ab3
2026-06-26 14:38:12 -07:00
gsxdsm
7137e36ccb FN-7073: serve file previews inline
File viewer previews now request inline-safe responses while downloads remain attachments.

- Add an inline preview query option to file download URL helpers and preview consumers.
- Serve known media and PDF preview extensions with real MIME types, inline disposition, nosniff, and sandbox CSP headers.
- Keep explicit downloads and unknown file types on attachment/octet-stream behavior.
- Cover preview and download header behavior with dashboard route and component tests.

Files changed:
 .changeset/fn-7073-file-viewer-inline-preview.md   |   7 +
 docs/dashboard-guide.md                            |   2 +-
 packages/dashboard/app/api/legacy.ts               |   9 +-
 .../dashboard/app/components/DockFilesView.tsx     |   2 +-
 .../dashboard/app/components/FileBrowserModal.tsx  |   2 +-
 .../components/__tests__/DockFilesView.test.tsx    |  14 +-
 .../components/__tests__/FileBrowserModal.test.tsx |  12 +-
 .../register-file-workspace-routes.test.ts         | 141 +++++++++++++++++++++
 .../src/routes/register-file-workspace-routes.ts   | 111 +++++++++++-----
 9 files changed, 260 insertions(+), 40 deletions(-)

Fusion-Task-Id: FN-7073
Fusion-Task-Lineage: 922b4aa4-ac6d-4a59-b94f-bab4eeb65530
2026-06-26 14:33:58 -07:00
gsxdsm
4f01c4dba1 FN-7075: backfill session models for token analytics
Backfill resolved pi session models so token analytics can show every model bucket.\n\n- Mirror explicit model overrides onto sessions that do not expose a model snapshot.\n- Cover multi-model token grouping totals and Command Center pie/table rendering.\n- Add a patch changeset for the dashboard token breakdown fix.\n\nFiles changed:\n .changeset/tidy-token-model-buckets.md             |  7 ++++++\n .../core/src/__tests__/token-analytics.test.ts     |  5 ++++\n .../areas/__tests__/TokensArea.test.tsx            |  5 ++++\n .../src/__tests__/pi-create-fn-agent.test.ts       | 28 ++++++++++++++++++++++\n packages/engine/src/pi.ts                          | 10 +++++++-\n 5 files changed, 54 insertions(+), 1 deletion(-)

Fusion-Task-Id: FN-7075

Fusion-Task-Lineage: 5f026435-5c3c-4e83-aab4-c1d7a487685a
2026-06-26 14:22:13 -07:00
gsxdsm
e89a58f276 FN-7066: schedule fixes for failed optional steps
Route failed pre-merge optional workflow steps back through executor remediation before review/merge.

- Add a graph-executor seam that schedules bounded executor fixes for pre-merge optional REVISE results.
- Track optional-step fix attempts with the existing post-review fix budget before falling back to advisory/gate behavior.
- Cover optional Code Review / Browser Verification fix scheduling and exhausted-budget behavior with engine tests.
- Document the pre-merge remediation semantics and add a release changeset.

Files changed:
 .changeset/fn-7066-optional-step-fix.md            |   7 +
 docs/workflow-steps.md                             |  11 +-
 packages/engine/src/__tests__/self-healing.test.ts |  43 +++++
 .../workflow-graph-optional-group.test.ts          | 206 +++++++++++++++++++++
 .../workflow-graph-optional-step-fix.test.ts       |  89 +++++++++
 packages/engine/src/executor.ts                    |  50 ++++-
 packages/engine/src/workflow-graph-executor.ts     |  29 +++
 packages/engine/src/workflow-graph-task-runner.ts  |   5 +-
 8 files changed, 436 insertions(+), 4 deletions(-)

Fusion-Task-Id: FN-7066

Fusion-Task-Lineage: 6b584293-4f2a-4851-a0d7-3ec9e68fe31a
2026-06-26 14:17:07 -07:00
gsxdsm
2db8ead842 FN-7071: show concurrency utilization in the footer panel
Expose live running-agent utilization in the footer concurrency controls.

- Show all-project and current-project running counts beside the matching concurrency sliders.
- Add clamped current-use markers on global and project slider tracks.
- Preserve shared global-concurrency hook state with utilization counts and cover the new UI behavior with tests.
- Document the footer panel utilization indicators and add a release changeset.

Files changed:
 .changeset/fn-7071-concurrency-running-counts.md   |   7 ++
 docs/dashboard-guide.md                            |   2 +-
 .../dashboard/app/components/EngineControlMenu.css |  23 ++++
 .../dashboard/app/components/EngineControlMenu.tsx | 103 +++++++++++++-----
 .../__tests__/EngineControlMenu.test.tsx           | 117 ++++++++++++++++++++-
 .../hooks/__tests__/useGlobalConcurrency.test.ts   |  96 +++++++++++++++++
 .../dashboard/app/hooks/useGlobalConcurrency.ts    |  41 +++++++-
 packages/i18n/locales/en/app.json                  |   4 +-
 packages/i18n/locales/es/app.json                  |   4 +-
 packages/i18n/locales/fr/app.json                  |   4 +-
 packages/i18n/locales/ko/app.json                  |   4 +-
 packages/i18n/locales/zh-CN/app.json               |   4 +-
 packages/i18n/locales/zh-TW/app.json               |   4 +-
 13 files changed, 373 insertions(+), 40 deletions(-)

Fusion-Task-Id: FN-7071

Fusion-Task-Lineage: db95d50a-c042-4972-a462-1987b7bca61e
2026-06-26 13:57:00 -07:00
gsxdsm
3c09008748 FN-7072: reduce skill metadata typography
Make the Skills detail pane render metadata and markdown content more compactly.

- Add scoped font-size reductions for plain-text and markdown skill detail content.
- Preserve shared mailbox markdown typography by limiting the new sizing to SkillsView selectors.
- Add a patch changeset for the published Fusion CLI package.

Files changed:
 .changeset/fn-7072-skill-metadata-font-size.md   | 7 +++++++
 packages/dashboard/app/components/SkillsView.css | 8 +++++++-
 2 files changed, 14 insertions(+), 1 deletion(-)

Fusion-Task-Id: FN-7072

Fusion-Task-Lineage: 6270be52-d52c-4969-ae65-ec4f10167ff2
2026-06-26 13:51:32 -07:00
gsxdsm
a61127de3b FN-7070: harden self-healing fake overlap seams
Strengthen self-healing tests so TaskStore fakes cover overlap-related seams deterministically.

- Add a focused regression for active file-scope overlap preservation in clearStaleBlockedBy().
- Teach existing self-healing fake stores to expose parsed file-scope and completion-handoff seams.
- Adjust assertions around queued, soft-delete, retry-exhausted, and finalize recovery paths to preserve overlap blockers.

Files changed:
 .../invariant-stranded-in-review-recovery.test.ts  | 16 +++-
 .../engine/src/__tests__/project-engine.test.ts    |  6 ++
 .../completion-fanout-x-self-healing.test.ts       |  6 ++
 ...view-retry-exhausted-policy-convergence.test.ts | 11 ++-
 .../self-healing-interactions.test.ts              |  6 ++
 ...ker-auto-finalize-interactions.real-git.test.ts |  8 +-
 .../soft-delete-deadlock-scan-exclusion.test.ts    |  6 ++
 .../self-healing-fake-overlap-seam.test.ts         | 93 ++++++++++++++++++++++
 .../self-healing-stale-merge-fanout.test.ts        |  7 ++
 9 files changed, 153 insertions(+), 6 deletions(-)

Fusion-Task-Id: FN-7070

Fusion-Task-Lineage: adb51873-9d8f-418f-ba60-c8a49601a552
2026-06-26 13:46:54 -07:00
gsxdsm
74d37785d2 FN-7069: reconcile phantom task reservations
Harden task-store startup and maintenance against phantom committed task reservations.

- Reconcile committed reservation phantoms without freeing reserved task IDs.
- Prune orphaned child rows and emit durable run-audit evidence.
- Normalize missing legacy task.json reads to clean not-found errors.
- Cover archive/search and phantom-reservation reconciliation behavior with tests.

Files changed:
 .changeset/fn-7069-phantom-task-reconcile.md       |   7 +
 AGENTS.md                                          |   1 +
 docs/architecture.md                               |   2 +
 .../src/__tests__/store-archive-search.test.ts     |   5 +
 .../store-phantom-reservation-reconcile.test.ts    | 148 +++++++++++++++++++++
 packages/core/src/store.ts                         | 106 ++++++++++++++-
 packages/engine/src/self-healing.ts                |  14 ++
 7 files changed, 282 insertions(+), 1 deletion(-)

Fusion-Task-Id: FN-7069

Fusion-Task-Lineage: 772aad37-db30-4310-a968-c6e5306c73bb
2026-06-26 13:39:33 -07:00
gsxdsm
0afc66b6be FN-7068: rescue quarantined flaky tests
Rescue quarantined dashboard and engine tests before the deletion deadline.

- Realign the DevServerView mobile CSS test with split mobile rules and balanced at-rule extraction.
- Complete FN-5488 self-healing TaskStore fakes for overlap-scope paths.
- Remove rescued dashboard and engine tests from quarantine configs and the ledger.

Files changed:
 .../__tests__/DevServerView.mobile.test.tsx        | 74 ++++++++++++++++++----
 packages/dashboard/vitest.config.ts                |  8 +--
 ...in-review-merge-stall-deadlock-recovery.test.ts |  7 ++
 ...f-healing-fn-5488-fast-path-regressions.test.ts |  6 ++
 packages/engine/vitest.config.ts                   |  8 +--
 scripts/lib/test-quarantine.json                   | 18 +-----
 6 files changed, 79 insertions(+), 42 deletions(-)

Fusion-Task-Id: FN-7068

Fusion-Task-Lineage: b40a551f-8981-49a1-86a3-660f08cceb94
2026-06-26 13:32:35 -07:00
gsxdsm
31d3f21e18 FN-7065: add deterministic Fusion co-author trailers
Fusion now applies co-author attribution through merge and worktree plumbing instead of relying on prompt-written commit messages.

- Add commit-msg hook support for deterministic Co-authored-by trailers with configured Fusion identity.
- Propagate commit attribution settings through native and worktrunk worktree backends.
- Backfill AI squash merge trailers with Fusion task metadata and co-author attribution.
- Document the settings behavior and add a patch changeset for published CLI behavior.
- Cover hook, executor, AI merge, and real-git trailer behavior with tests.

Files changed:
 .changeset/fn-7065-co-author-trailer.md            |  7 +++
 docs/settings-reference.md                         |  6 +--
 packages/engine/src/__tests__/merger-ai.test.ts    | 43 +++++++++++++++++++
 .../real-git/commit-msg-trailer.real-git.test.ts   | 50 ++++++++++++++++++++++
 .../engine/src/__tests__/worktree-hooks.test.ts    | 15 +++++++
 packages/engine/src/executor.ts                    |  4 ++
 packages/engine/src/merger-ai.ts                   | 22 ++++++++--
 packages/engine/src/step-session-executor.ts       |  3 ++
 packages/engine/src/worktree-acquisition.ts        |  3 ++
 packages/engine/src/worktree-backend.ts            | 13 +++++-
 packages/engine/src/worktree-hooks.ts              | 33 +++++++++++++-
 11 files changed, 190 insertions(+), 9 deletions(-)

Fusion-Task-Id: FN-7065

Fusion-Task-Lineage: 4f5cd0ff-7193-4f97-bdcd-4cd78c7669b9
2026-06-26 13:13:46 -07:00
gsxdsm
fa4ee607b7 chore(release): v0.49.0
Version bump via changesets.
2026-06-26 12:06:05 -07:00
gsxdsm
f685518a93 FN-7064: discover MCP servers in settings
Add read-only MCP discovery with settings UI controls that keep discovered secrets bound to Fusion secret references.

- Add core MCP discovery source resolution and parsing for supported global and project tool configs.
- Expose discovered MCP server candidates through the dashboard API and engine discovery service.
- Surface discovered servers in global and project MCP settings with explicit add flows and configured-state handling.
- Require discovered sensitive env/header/token descriptors to stay locked until bound or created as Fusion secret references.
- Document discovery behavior and add a published package changeset.

Files changed:
 .changeset/fn-7064-mcp-auto-discovery.md           |   7 ++
 docs/dashboard-guide.md                            |   3 +-
 docs/mcp.md                                        |  53 ++++++++-
 docs/settings-reference.md                         |   4 +-
 packages/core/src/__tests__/mcp-discovery.test.ts  |  74 ++++++++++++
 packages/core/src/index.ts                         |   7 ++
 packages/core/src/mcp-discovery.ts                 | 125 ++++++++++++++++++++
 .../__tests__/SettingsModal.mcp.test.tsx           |  76 +++++++++++-
 .../settings/sections/McpServersCard.css           |  34 +++++-
 .../settings/sections/McpServersCard.tsx           | 130 ++++++++++++++++++++-
 .../src/__tests__/mcp-discovered-route.test.ts     | 109 +++++++++++++++++
 packages/dashboard/src/routes.ts                   |  46 ++++++++
 .../src/__tests__/mcp-discovery-service.test.ts    |  60 ++++++++++
 packages/engine/src/index.ts                       |   1 +
 packages/engine/src/mcp-discovery-service.ts       |  65 +++++++++++
 15 files changed, 782 insertions(+), 12 deletions(-)

Fusion-Task-Id: FN-7064
Fusion-Task-Lineage: ef5dc53f-f8d1-4cc8-bdaf-e98d63ee8406
2026-06-26 11:56:12 -07:00
gsxdsm
bf51f1b740 fix(FN-7039): show enabled workflow steps in the detail progress bar (#1790)
## Show enabled workflow steps in the detail progress bar (FN-7039
follow-up)

Follow-up to the now-merged graph-native workflow-steps refactor
(#1788).

**Problem:** the Task detail modal's Progress bar mapped only
`workingTask.steps` (implementation steps), so an **enabled optional
workflow step** (e.g. "Code Review") got **no segment** — even though
the cards/list already include them.

**Fix:** drive the detail bar from `getUnifiedTaskProgress` (the same
unified model the cards use), so each enabled workflow step renders its
own segment — including the enabled-but-not-yet-run (pending) state.
`getStepStatusColor` is extended to the workflow statuses
(`passed`→success, `failed`→error, `advisory_failure`→amber,
`running`→in-progress), and segments get a `--source-workflow` modifier.
Adds a regression test asserting enabled steps render segments.

**Verification:** dashboard typecheck clean;
`TaskDetailModal.models-progress-workflow` (45) + `taskProgress` (9)
tests green; lint clean.

🤖 Generated with [Claude Code](https://claude.com/claude-code)


<!-- stage-review-badge-begin -->

---

<a href="https://stagereview.app/Runfusion/Fusion/pull/1790">
  <picture>
<source media="(prefers-color-scheme: dark)"
srcset="https://stagereview.app/assets/gh-open-in-stage-dark.svg">
<img src="https://stagereview.app/assets/gh-open-in-stage-light.svg"
alt="Open in Stage">
  </picture>
</a>

<!-- stage-review-badge-end -->

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

## Summary by CodeRabbit

* **New Features**
* Task progress now shows a unified step view, combining implementation
and workflow steps in the progress bar.
* The step count label now reflects total completed steps out of all
visible steps.

* **Bug Fixes**
* Progress segments now support additional workflow states, including
passed, advisory failure, and running.
* Added regression coverage to ensure workflow-derived progress segments
render with the correct status styling.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-06-26 11:53:15 -07:00
gsxdsm
88e3d8881e fix(FN-7039): show enabled workflow steps as segments in the detail progress bar
The TaskDetailModal Progress bar mapped only workingTask.steps, so enabled optional
workflow steps (e.g. Code Review) had no segment. Drive it from getUnifiedTaskProgress
(the same model the cards use) so each enabled step gets a segment — even before it runs
(pending) — and extend getStepStatusColor to the workflow statuses (passed/failed/
advisory_failure/running). Adds a regression test asserting enabled steps render segments.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 11:16:02 -07:00
gsxdsm
7a3a9a9bb1 FN-7062: rename remote settings section
Rename the settings navigation entry so Remote Access is no longer conflated with Node Sync.

- Update the remote settings nav label to "Remote Access" while keeping the separate Node Sync section intact.
- Add coverage that rejects the old combined label and confirms both standalone entries render.
- Align the workflow settings plan and changeset with the clarified settings IA.

Files changed:
 .changeset/fn-7062-remote-access-rename.md               |  7 +++++++
 ...26-06-04-002-feat-workflow-settings-mechanism-plan.md |  2 +-
 packages/dashboard/app/components/SettingsModal.tsx      |  6 +++++-
 .../__tests__/SettingsModal.scheduling-merge.test.tsx    | 16 ++++++++++++++++
 4 files changed, 29 insertions(+), 2 deletions(-)

Fusion-Task-Id: FN-7062

Fusion-Task-Lineage: d50d47eb-aa15-4bf6-8f26-edaa79c8de9e
2026-06-26 10:18:04 -07:00
gsxdsm
2442032382 FN-7061: Graduate Remote Access settings
Remote Access settings are now always available while tunnel prerequisites remain gated.

- Remove Remote Access from experimental feature toggles and section visibility gates.
- Keep legacy remoteAccess experimental flags hidden so upgrades cannot disable the section.
- Update settings and remote access docs plus release notes for the graduated UI.
- Cover always-visible Remote Access behavior across missing and legacy experimental flag states.

Files changed:
 .changeset/fn-7061-remote-access-graduation.md     |  7 +++
 docs/remote-access.md                              |  2 +-
 docs/settings-reference.md                         |  1 +
 .../dashboard/app/components/SettingsModal.tsx     | 17 ++----
 .../SettingsModal.remote-notifications.test.tsx    | 13 +++++
 .../SettingsModal.scheduling-merge.test.tsx        | 60 ++++++++++++----------
 6 files changed, 60 insertions(+), 40 deletions(-)

Fusion-Task-Id: FN-7061

Fusion-Task-Lineage: 2e6a6977-b43b-4c7b-8100-0f2f2f018fcf
2026-06-26 10:18:04 -07:00
gsxdsm
42f46a12c1 FN-7060: sanitize bundled plugin manifests
Sanitize published CLI plugin manifests so off-workspace installs do not resolve private workspace packages.

- Add manifest sanitization for copied bundled plugins and vendored pi extensions during the CLI build.
- Cover built plugin and extension package.json files with a pack-shape regression test.
- Update plugin authoring docs and add a patch changeset for the published CLI fix.

Files changed:
 .../fn-7060-fix-plugin-manifest-workspace-deps.md  |  7 ++
 docs/PLUGIN_AUTHORING.md                           |  8 ++-
 .../cli/src/__tests__/plugin-pack-shape.test.ts    | 55 +++++++++++++-
 packages/cli/tsup.config.ts                        | 83 ++++++++++++++++++++--
 4 files changed, 142 insertions(+), 11 deletions(-)

Fusion-Task-Id: FN-7060

Fusion-Task-Lineage: e38a4237-7197-4bc4-87bd-117dfd35a0f8
2026-06-26 10:18:04 -07:00
gsxdsm
819c626466 fix(mobile-chat): hide executor footer and remove gap above keyboard (#1789)
## Problem

On mobile, when the soft keyboard is up in Chat, the executor footer
(task counts / **Running** indicator) stayed visible and there was a
dead band of empty space between the composer and the keyboard.

Root cause: `computeMobileBarKeyboardFlags` gated the footer-hide +
padding-strip to **iOS only**. On Android `footerHidden` stayed `false`,
so `ExecutorStatusBar` kept rendering **and** `.project-content` kept
reserving `footer-height + nav-height` (~80px) of `padding-bottom`. The
mobile nav bar is slid off-screen (`translateY(100%)`) when the keyboard
is up, so that reserved space rendered as the empty gap.

## Fix

Drop the `&& isIOS` gate on `footerHidden` so Android matches iOS. When
the keyboard is open on mobile:
- `ExecutorStatusBar` is hidden (no task-count/Running footer), and
- `.project-content` reserves no footer/nav padding, so the composer
sits flush above the keyboard.

`footerKeyboardOpen` (the iOS `bottom: 0` footer-collapse class) stays
iOS-only — it only matters when the footer is still rendered over a
modal. Modal / Quick-Chat-overlay keyboard cases are unchanged
(`boardLayoutSuppressed`).

## Before / After

| Before | After |
| --- | --- |
| Footer shown + empty gap above keyboard | Footer hidden, composer
flush above keyboard |

_(Rendered with the real component CSS at a mobile viewport with the
keyboard-open classes applied.)_

## Notes / verification

- File-scoped tests pass: `mobileBarKeyboardFlags`,
`mobile-bottom-bars-keyboard-layout`, App keyboard-layout cases,
`footer-safe-layout`, `dashboard-footer-mobile-layout`,
`ChatView.mobile-render` (46 tests).
- FN-5707 originally gated this to iOS over a concern that stripping nav
padding mid-focus could make Android Chrome dismiss the keyboard. The
strip is keyed off `keyboardOpen`, which only flips `true` after the
visual viewport settles into its keyboard-open size — but **please
confirm on a real Android device** that the keyboard stays up when
tapping the composer. If it dismisses, the fallback is a transform-based
hide that avoids the reflow.

🤖 Generated with [Claude Code](https://claude.com/claude-code)


<!-- stage-review-badge-begin -->

---

<a href="https://stagereview.app/Runfusion/Fusion/pull/1789">
  <picture>
<source media="(prefers-color-scheme: dark)"
srcset="https://stagereview.app/assets/gh-open-in-stage-dark.svg">
<img src="https://stagereview.app/assets/gh-open-in-stage-light.svg"
alt="Open in Stage">
  </picture>
</a>

<!-- stage-review-badge-end -->
2026-06-26 10:17:37 -07:00
gsxdsm
e48c75ccc5 fix(mobile-chat): hide executor footer and remove gap above keyboard
On Android the keyboard-open footer (executor status bar) stayed visible
and the off-screen mobile nav bar's reserved padding rendered as an empty
band between the composer and the keyboard. computeMobileBarKeyboardFlags
no longer iOS-gates footerHidden, so both platforms now hide the footer
and drop the reserved footer+nav padding-bottom when the soft keyboard is
up, letting the composer sit flush above the keyboard. footerKeyboardOpen
(the iOS bottom:0 collapse class) stays iOS-only.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 09:32:53 -07:00
gsxdsm
64647eb28e FN-7039: graph-native workflow steps (U1–U8) (#1788)
## FN-7039: graph-native workflow steps (complete — U1–U8)

Fixes the FN-7039 report — *optional workflow steps were marked done
without running, and didn't show in the step progress bar* — and
migrates workflow steps **entirely** onto the workflow-graph machinery,
removing the legacy parallel system end-to-end. Plan:
`docs/plans/2026-06-25-001-refactor-workflow-steps-graph-native-plan.md`.

### Root cause
`Store.optionalGroupIdSet()` returned an empty set when a task had no
explicit `workflowId` and the project had no `defaultWorkflowId`, so a
built-in group id (`browser-verification`) collided with a template id
and was materialized into a legacy `WS-xxx` row the graph executor never
matched. Graph-run steps also never recorded results, so the progress
bar stayed empty.

### What changed
- **U1** — `optionalGroupIdSet` → `builtin:coding` fallback; create-time
toggles resolve `builtin:coding`. Enabled built-in group ids no longer
downgraded.
- **U2** — the graph executor records each enabled optional-group step
into `task.workflowStepResults` (keyed by node id) + emits `[pre-merge]`
logs.
- **U3** — progress bar + Workflow tab read graph-written results;
dropped `workflowStepNameLookup`; added running / advisory-vs-blocking
render states.
- **U4** — deleted the legacy `runWorkflowSteps` execution path +
`workflow-step` seam/primitive; watchdog re-enters the graph;
store-fallback fails closed.
- **U5** — removed the `/api/workflow-steps*` REST surface + Settings →
Workflow Steps UI.
- **U6** — deleted `WORKFLOW_STEP_TEMPLATES` (inlined into the IR
builders); plugin templates remain as the editor palette.
- **U7** — **post-merge made graph-native and the legacy table
removed**:
- **U7a** post-merge steps run as graph nodes after `merge-attempt`
(flag-gated; built-in `coding` byte-identical when off).
- **U7b** `graphNativePostMerge` default-ON; merger post-merge path made
inert (no double-run, proven); migration 130 normalizes built-in enable
ids (`WS-004` → `browser-verification`). Verified against real DBs: **no
custom/plugin post-merge steps exist**; the only post-merge step
(compound-engineering's `document`) already runs as a graph node.
- **U7c** removed every remaining `workflow_steps` reader/writer (merger
post-merge code, store CRUD, `materializeWorkflowSteps`, executor
recovery read) and **dropped the table** (migration 131).
`materializeWorkflowSteps` was proven vestigial (the graph runs IR
nodes, never compiled rows).
- **U8** — docs rewritten to the graph-native model;
`settings-reference` updated.
- **Review fixes** — dead-code cleanup, step output/notes recording,
engine/core seam-contract sync.

### Verification
- `pnpm test:gate` green (engine-core 298, ci-shape 58); **`pnpm
smoke:boot` PASS** (app boots + `/api/health` 200 with the table gone);
full `@fusion/core` suite (6290) + reliability backstop (154) green;
core/engine/dashboard typecheck clean; seed-at-129 and seed-at-130
migration tests green.
- 4-persona code review
(correctness/adversarial/reliability/maintainability) on U1–U6;
`safe_auto` + on-goal fixes applied.

### Decision provenance
A six-reviewer doc review changed two foundations (see the plan revision
note): the graph writes the **existing `workflowStepResults` field** (no
new table — avoids upgrade data loss), and "drop the table" was found
unsafe until post-merge went graph-native (the user opted to do the full
post-merge rebuild + drop in this PR).

## Residual Review Findings (follow-up)
- **[P2] FN-4343 per-step scope gate not replicated on the graph path**
— the per-step `workflowStepScopeEnforcement` leak check lived only in
the deleted `runWorkflowSteps`. Merge-time `FileScopeViolationError` +
squash-overlap are unaffected; a coding-capable user-authored step could
write off-scope files that ride along to merge. Re-introduce post-node
scope enforcement on the graph path.
- **[P2] Recording for non-optional-group / split-branch step
realizations** — `recordWorkflowStepResult` fires only for
`optional-group` nodes in the main traversal; built-in gates record
correctly.
- **[P3] Misleading recovery log** — `recoverCompletedTask` logs
success-flavored "Auto-recovered…" even when the graph parked the task
`failed` (observability only).
- **[P3] Malformed-advisory verdict maps to `passed`** rather than
`advisory_failure`. Edge case.
- **[testing] Fail-closed store-capability test** — assert all
production store constructions expose `getTaskWorkflowSelection`.

🤖 Generated with [Claude Code](https://claude.com/claude-code)


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

* **Bug Fixes**
* Optional workflow steps now consistently run and appear in task
progress, including when no project default workflow is set.
* Task progress now derives workflow step names and statuses from
recorded results, showing correct **running** and non-blocking
**advisory-failure** behavior, while excluding disabled steps from
totals.
* **New Features**
* Post-merge optional steps now run **graph-native by default** and
remain non-blocking on revise outcomes.
* **Removals**
* Removed legacy workflow-step CRUD/refinement flows and the built-in
template-catalog-based model; workflow steps now rely on the
graph-native optional-group approach.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-06-26 09:19:40 -07:00
gsxdsm
01f198483b fix(lint): drop unused imports in routes.ts after legacy workflow-step route removal
WorkflowStepTemplate and resolvePlanningSettingsModel were only used by the deleted
/api/workflow-steps CRUD + :id/refine routes (U5); the imports survived the merge as
unused. Remove them. No behavior change.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 09:09:36 -07:00
gsxdsm
fca2ff6efb fix(FN-7039): render workflow steps with proper casing in the progress UI
An enabled-but-not-yet-run workflow step has no recorded result, so the progress bar
previously showed the raw graph node id (e.g. 'code-review'). Humanize the id fallback to
Title Case ('Code Review', 'Browser Verification', 'Frontend UX Design'). Once the step
runs, the graph-recorded config.name still wins; humanization is only the pre-run fallback.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 08:53:26 -07:00
gsxdsm
3ee47dec86 merge: integrate origin/main into feature/workflow-steps (FN-7039)
Resolve conflicts from 56 upstream commits:
- db.ts: renumber my migrations around main's new migration 130 (columnDwellMs) —
  enable-id normalization 130→131, drop-table 131→132, SCHEMA_VERSION→132.
- index.ts / routes.ts: take main's new MCP exports/imports; keep WORKFLOW_STEP_TEMPLATES
  array removed (kept the WorkflowStepTemplate type).
- merger.ts: keep the legacy post-merge execution path removed (U7c) over main's version.
- ci-workflow.test.ts (from main): add port-4040/process-supervisor allowlist markers to
  the gate-script assertions that reference the checker filenames (pre-existing self-match).

Gate green (engine-core 299, ci-shape 62); boot smoke PASS; migration tests + typecheck clean.
2026-06-26 08:50:22 -07:00
gsxdsm
005322eeaa fix(review): address PR #1788 review feedback
- workflow-graph-executor: wrap each post-merge walk() in try/catch so a malformed
  post-merge IR / traversal error is logged and skipped, never flipping an already-
  merged task to failed (non-blocking post-merge contract) [T9, real bug].
- Refresh stale FNXC comments now that graphNativePostMerge is default-ON and the
  legacy merger post-merge path was removed (experimental-features, workflow-graph-
  executor, workflow-graph-post-merge.test) [T6/T7/T8].
- Normalize FNXC timestamps to yyyy-MM-dd-hh:mm (TaskCard.test, taskProgress.test) [T2/T3].
- Changeset: category fix → feature to match the minor bump [T0].

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 08:40:59 -07:00
gsxdsm
7d13f880ba FN-7059: pin merge gate composition
Add CI-shape coverage that guards the trusted merge gate composition.\n\n- Load root and engine package scripts plus the engine vitest config in the CI workflow test.\n- Assert test:gate includes the audited guard scripts, engine core suite, and CLI CI-shape suite.\n- Assert engine test:core continues targeting the engine-core vitest project.\n\nFiles changed:\n packages/cli/src/__tests__/ci-workflow.test.ts | 26 ++++++++++++++++++++++++++\n 1 file changed, 26 insertions(+)

Fusion-Task-Id: FN-7059

Fusion-Task-Lineage: 47af7fdd-a812-4d03-960a-a6300d86b59e
2026-06-26 06:47:27 -07:00
gsxdsm
2b554142f5 FN-7056: guard configured commands against execSync
Add a focused engine regression guard for user-configured command paths.

- Add a static Vitest registry that slices protected configured-command helpers and fails on execSync usage.
- Assert each protected command path keeps bounded async safeguards such as timeout, maxBuffer, or maxLifetimeMs.
- Document the guard and its deliberate git-plumbing exclusions in the testing guide.

Files changed:
 docs/testing.md                                    |   5 +
 .../user-configured-command-no-execsync.test.ts    | 288 +++++++++++++++++++++
 2 files changed, 293 insertions(+)

Fusion-Task-Id: FN-7056

Fusion-Task-Lineage: b92f19cf-526e-4345-b18e-869a278e0e10
2026-06-26 04:11:04 -07:00
gsxdsm
d03d6c23d6 FN-7057: preserve workflow selections across dashboard surfaces
Add regression coverage and stale-workflow fallback for workflow-aware dashboard selection.

- Cover cached board-workflow hydration across remounted Header and Graph switchers.
- Verify Header and Graph selections remain isolated while Graph task filtering follows the Graph selection.
- Treat deleted workflow assignments as default-workflow tasks so they remain visible.
- Add hook coverage for cache hydration, project changes, selection fallbacks, disabled workflow mode, and consumer isolation.
- Add a patch changeset for the stale Graph workflow filtering fix.

Files changed:
 .changeset/fn-7057-graph-workflow-filter.md        |   7 +
 .../workflow-selection-cross-surface.test.tsx      | 184 +++++++++++++++++++++
 .../app/components/GraphWorkflowSwitcherSlot.tsx   |  11 +-
 .../__tests__/GraphWorkflowSwitcherSlot.test.tsx   |   1 +
 .../app/hooks/__tests__/useBoardWorkflows.test.ts  | 133 ++++++++++++++-
 5 files changed, 330 insertions(+), 6 deletions(-)

Fusion-Task-Id: FN-7057

Fusion-Task-Lineage: 52e6682a-576e-4ed6-92d5-03e0e9b5896c
2026-06-26 04:06:32 -07:00
gsxdsm
4e59d74920 FN-7058: refresh test velocity quarantine baseline
Refresh the test velocity report so it reflects the current quarantine ledger.

- Update the weekly baseline quarantine count from 0 to 3.
- Reflect the three new quarantines in age-bucket and delta tables.
- Update the #leads posting snippet with the new quarantine ledger total.

Files changed:
 docs/test-velocity-baseline.md | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

Fusion-Task-Id: FN-7058
Fusion-Task-Lineage: c8d40858-3511-4962-9f33-01d144cb6dae
2026-06-26 03:50:38 -07:00
gsxdsm
3bfdb16650 FN-7033: document MCP operator workflows
Add a canonical MCP guide with operator workflows and contract coverage.

- Add docs/mcp.md covering MCP settings resolution, transports, secret references, validation, dashboard management, CLI commands, import/export, and AI lane forwarding.
- Link the MCP guide from the docs index, CLI reference, settings reference, secrets docs, and dashboard guide.
- Add a documentation contract test that checks required guide sections and source-aligned MCP surfaces.

Files changed:
 docs/README.md                                     |   1 +
 docs/cli-reference.md                              |   2 +-
 docs/dashboard-guide.md                            |   2 +-
 docs/mcp.md                                        | 221 +++++++++++++++++++++
 docs/secrets.md                                    |   2 +-
 docs/settings-reference.md                         |   2 +
 .../src/__tests__/mcp-documentation.test.ts        |  65 ++++++
 7 files changed, 292 insertions(+), 3 deletions(-)

Fusion-Task-Id: FN-7033

Fusion-Task-Lineage: 530abc69-0247-49ee-9487-54d8e2a1b988
2026-06-26 02:52:51 -07:00
gsxdsm
8131d541ca FN-7038: add live automation run output
Add configurable automation tool access with live manual-run streaming for schedules and routines.

- Add an automation tool allowlist model and dashboard selectors for AI prompt steps.
- Stream manual automation and routine run progress, output, step updates, and tool events over SSE.
- Surface live run transcripts in automation/routine cards and document the operator workflow.
- Cover validation, runner callbacks, API streaming, and UI behavior with targeted tests.

Files changed:
 .changeset/fn-7038-automation-tools-live-output.md |   7 +
 docs/dashboard-guide.md                            |   9 +
 packages/core/src/__tests__/automation.test.ts     |  27 +-
 packages/core/src/automation.ts                    |  18 +
 packages/core/src/index.ts                         |   4 +-
 packages/core/src/types.ts                         |   6 +
 packages/dashboard/app/api/legacy.ts               |  48 +++
 packages/dashboard/app/components/RoutineCard.tsx  |  16 +-
 packages/dashboard/app/components/ScheduleForm.tsx |  53 ++-
 .../app/components/ScheduleStepsEditor.tsx         |  49 ++-
 .../app/components/ScheduledTasksModal.tsx         |  72 +++-
 packages/dashboard/app/components/ScriptsModal.css |  79 ++++
 .../app/components/__tests__/RoutineCard.test.tsx  |  45 +++
 .../app/components/__tests__/ScheduleForm.test.tsx | 100 +++++-
 .../__tests__/ScheduleStepsEditor.test.tsx         |  67 +++-
 .../__tests__/ScheduledTasksModal.test.tsx         |  36 +-
 .../src/__tests__/routes-automation.test.ts        | 151 +++++++-
 packages/dashboard/src/routes.ts                   | 400 ++++++++++++++++++++-
 packages/dashboard/src/server.ts                   |   7 +-
 packages/engine/src/__tests__/cron-runner.test.ts  |  56 ++-
 .../src/__tests__/pi-create-fn-agent.test.ts       |  44 +++
 .../engine/src/__tests__/routine-runner.test.ts    |  28 ++
 packages/engine/src/cron-runner.ts                 |  20 +-
 packages/engine/src/pi.ts                          |  32 +-
 packages/engine/src/routine-runner.ts              |  39 +-
 packages/i18n/locales/en/app.json                  |   9 +
 packages/i18n/src/resources.d.ts                   |  21 ++
 27 files changed, 1374 insertions(+), 69 deletions(-)

Fusion-Task-Id: FN-7038

Fusion-Task-Lineage: 7f5871d0-1de0-4d22-a9c9-ee9418658677
2026-06-26 02:45:29 -07:00
gsxdsm
c0f9f2b4a9 docs(FN-7039): rewrite workflow-steps docs to the graph-native model
Reflect the completed cutover: quality gates are optional-group IR nodes (pre- and
post-merge), results live on task.workflowStepResults (graph-written), custom gates are
authored in the Workflow Editor, plugin templates are the palette. Removed docs for the
deleted runWorkflowSteps path, WORKFLOW_STEP_TEMPLATES catalog, /api/workflow-steps CRUD,
Settings → Workflow Steps manager, and the workflow_steps table. Documented
experimentalFeatures.graphNativePostMerge (default-ON) and the FN-4343 per-step scope-gate
follow-up. settings-reference: add graphNativePostMerge, annotate workflowStepScopeEnforcement.

Plan U8.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 02:38:31 -07:00
gsxdsm
301f25da06 FN-7025: add MCP server management settings UI
Adds dashboard controls for managing MCP server configuration across global and project scopes.

- Add global and project MCP settings sections with server cards, validation, inheritance status, and import/export controls.
- Wire MCP settings into split-save behavior, browser-safe core exports, localization, and dashboard documentation.
- Cover MCP settings interactions and save routing with dashboard tests.

Files changed:
 .changeset/fn-7025-mcp-dashboard-ui.md             |   7 +
 docs/dashboard-guide.md                            |  14 +
 packages/core/src/types.ts                         |   4 +
 .../app/__tests__/settings-save-split.test.ts      |  25 +
 .../dashboard/app/components/SettingsModal.tsx     |  25 +
 .../__tests__/SettingsModal.mcp.test.tsx           | 228 +++++++++
 .../app/components/settings/save-split.ts          |   5 +
 .../settings/sections/GlobalMcpSection.tsx         |  26 ++
 .../settings/sections/McpServersCard.css           | 177 +++++++
 .../settings/sections/McpServersCard.tsx           | 515 +++++++++++++++++++++
 .../settings/sections/ProjectMcpSection.tsx        |  27 ++
 packages/i18n/locales/en/app.json                  |  10 +-
 packages/i18n/locales/es/app.json                  |  10 +-
 packages/i18n/locales/fr/app.json                  |  10 +-
 packages/i18n/locales/ko/app.json                  |  10 +-
 packages/i18n/locales/zh-CN/app.json               |  10 +-
 packages/i18n/locales/zh-TW/app.json               |  10 +-
 17 files changed, 1107 insertions(+), 6 deletions(-)

Fusion-Task-Id: FN-7025

Fusion-Task-Lineage: e4e59431-c819-464b-a04b-e470ac51c460
2026-06-26 02:30:34 -07:00