Commit Graph

1654 Commits

Author SHA1 Message Date
gsxdsm
de254858f2 Merge pull request #1498 from Runfusion/feature/engine-plugin
[codex] Add workflow extension plugin seams
2026-06-07 22:57:04 -07:00
gsxdsm
6d47d1abd0 fix(engine): tighten workflow extension feedback fixes 2026-06-07 22:21:48 -07:00
gsxdsm
01523a6581 fix(engine): address workflow extension PR feedback 2026-06-07 21:19:10 -07:00
gsxdsm
71822f26db feat(engine): add workflow extension plugin seams 2026-06-07 20:43:44 -07:00
gsxdsm
ffce26ab1d FN-5986: add browser demo lifecycle board flow
Add a browser demo workflow and supporting fixtures for board walkthroughs.

- add a demo README plus seeded Browser Demo Lifecycle workflow with Todo, In Progress, In Review, QA, and Publish columns
- seed representative browser demo tasks and lifecycle log entries across the custom workflow columns
- update the live simulator to advance workflow tasks through QA and Publish while preserving the legacy merge path
- add a core lifecycle test covering workflow selection and the Todo → In Progress → In Review → QA → Publish transitions

Files changed:
 demo/README.md                                     |  25 ++++
 demo/seed.ts                                       | 131 ++++++++++++++++++++-
 demo/simulate.ts                                   |  35 ++++--
 packages/core/src/__tests__/browser-demo-lifecycle.test.ts   |  71 +++++++++++
 4 files changed, 248 insertions(+), 14 deletions(-)

Fusion-Task-Id: FN-5986

Fusion-Task-Lineage: 9638f7da-9b50-4de1-8ffa-d861dbf7aff2
2026-06-07 20:25:00 -07:00
gsxdsm
d3a2c8863d FN-5945: narrow hot task updates to changed columns
Reduce SQLite and FTS churn on hot task-update paths.

- switch hot task writes to column-scoped UPDATE statements that touch only changed fields plus updatedAt
- keep create and replication-style persistence on full-row INSERT/UPSERT paths and rewrite task.json from the refreshed DB row after partial updates
- route executor lease renewals through renewCheckoutLease and add regression coverage plus storage docs for the narrower write paths

Files changed:
 docs/storage.md                                    |   5 +-
 .../core/src/__tests__/task-partial-update.test.ts | 191 ++++++
 packages/core/src/store.ts                         | 638 +++++++++++----------
 .../src/__tests__/executor-lease-renewal.test.ts   |  66 +++
 packages/engine/src/executor.ts                    |   2 +-
 5 files changed, 603 insertions(+), 299 deletions(-)

Fusion-Task-Id: FN-5945

Fusion-Task-Lineage: ad0c5b64-f411-4379-85ab-f81edfc18101
2026-06-07 20:15:26 -07:00
gsxdsm
3615b0b19d FN-5941: stop todo/in-progress flapping
Prevent scheduler and self-healing churn from bouncing live tasks between todo and in-progress.

- add dispatch oscillation settings, scheduler settle-window tracking, and auto-pause audit/logging for rapid todo↔in-progress cycles
- harden self-healing against reclaiming genuinely active tasks by checking executor activity, grace windows, and heartbeat runs before requeueing
- cover the new reliability invariants with focused engine tests and document the new diagnostics/settings behavior

Files changed:
 docs/architecture.md                               |   1 +
 docs/diagnostics.md                                |   9 +
 docs/settings-reference.md                         |   3 +
 .../core/src/__tests__/settings-parity.test.ts     |   6 +
 packages/core/src/settings-schema.ts               |   6 +
 packages/core/src/types.ts                         |   9 +
 .../todo-inprogress-flapping.test.ts               | 556 +++++++++++++++++++++
 packages/engine/src/__tests__/scheduler.test.ts    |  14 +-
 .../self-healing-in-progress-limbo.test.ts         |   2 +-
 packages/engine/src/__tests__/self-healing.test.ts |   8 +-
 packages/engine/src/run-audit.ts                   |   8 +
 packages/engine/src/scheduler.ts                   | 113 ++++-
 packages/engine/src/self-healing.ts                | 230 +++++++--
 13 files changed, 928 insertions(+), 37 deletions(-)

Fusion-Task-Id: FN-5941

Fusion-Task-Lineage: babdd85e-d04c-47ca-901c-db692b2874bf
2026-06-07 18:51:47 -07:00
gsxdsm
904e68143e FN-6006: name built-in workflow seam nodes
Ensure built-in workflow seams render readable labels instead of "Not configured".

- add explicit names to built-in execute, review, merge, planning, and step-execute seam nodes
- surface seam-specific summaries in dashboard node summaries, with a fallback for unknown seam values
- extend core and dashboard tests to cover seam naming invariants and rendered summaries

Files changed:
 .../__tests__/builtin-coding-workflow-ir.test.ts   |  7 +++++
 .../core/src/__tests__/builtin-workflows.test.ts   | 24 +++++++++++++++
 packages/core/src/builtin-coding-workflow-ir.ts    |  6 ++--
 .../src/builtin-stepwise-coding-workflow-ir.ts     |  8 ++---
 packages/core/src/builtin-workflows.ts             | 22 +++++++-------
 .../nodes/__tests__/node-summary.test.ts           | 35 ++++++++++++++++++++++
 .../dashboard/app/components/nodes/node-summary.ts | 17 +++++++++++
 7 files changed, 101 insertions(+), 18 deletions(-)

Fusion-Task-Id: FN-6006

Fusion-Task-Lineage: 198fc500-ac8f-45c9-b6b5-7aa15285d1df
2026-06-07 18:51:47 -07:00
gsxdsm
ec8e4d3b0d FN-5988: fix desktop startup by lazy-loading archive parser deps
Prevent desktop startup failures by deferring archive parser dependencies until archive parsing runs.

- lazy-load `extract-zip` and `tar` inside archive parsing paths instead of at module import time
- add regression tests covering helper-only imports and dynamic loading for zip/tgz archive parsing
- include the desktop package's required @fusion/core runtime dependency groups in electron-builder packaging

Files changed:
 .../src/__tests__/agent-companies-parser.test.ts   | 115 +++++++++++++++++++++
 packages/core/src/agent-companies-parser.ts        |   4 +-
 packages/desktop/electron-builder.yml              |  44 ++++++++
 3 files changed, 161 insertions(+), 2 deletions(-)

Fusion-Task-Id: FN-5988
Fusion-Task-Lineage: b31bf43b-791c-4cd1-a62f-7095badcb706
2026-06-07 18:51:46 -07:00
gsxdsm
61d687440b FN-5770: promote workflow interpreter to guarded lifecycle driver
Route default coding tasks through the workflow interpreter only when parity readiness checks pass.

- add a core cutover-readiness evaluator and exports for the workflowInterpreterAuthoritative flag
- wire a WorkflowAuthoritativeDriver into runtime dispatch and reuse authoritative lifecycle seams with legacy fallback behavior
- cover the cutover with reliability tests, docs updates, and a published CLI changeset

Files changed:
 .../FN-5770-workflow-interpreter-authoritative.md  |   5 +
 docs/architecture.md                               |   1 +
 docs/settings-reference.md                         |   5 +-
 docs/workflow-steps.md                             |  22 +-
 .../core/src/__tests__/workflow-cutover.test.ts    |  68 +++++
 packages/core/src/index.ts                         |   8 +
 packages/core/src/workflow-cutover.ts              |  81 ++++++
 .../src/__tests__/openclaw-runtime-e2e.test.ts     |   1 +
 .../engine/src/__tests__/pi-layers-wiring.test.ts  |   2 +-
 .../branch-recovery-live-zero-commits.test.ts      |   2 +-
 .../branch-recovery-stale-cached-base.test.ts      |   2 +-
 .../workflow-interpreter-cutover.test.ts           | 306 +++++++++++++++++++++
 .../self-healing-completion-fanout.test.ts         |   2 +-
 .../self-healing-ghost-branch-recovery.test.ts     |   2 +-
 .../self-healing-orphan-only-scope.test.ts         |   2 +-
 .../self-healing-reclaim-live-zero-commits.test.ts |   2 +-
 .../self-healing-stale-merger-status.test.ts       |   2 +-
 .../src/__tests__/step-session-executor.test.ts    |   2 +-
 .../__tests__/worktree-admin-entry-prune.test.ts   |   8 +-
 packages/engine/src/executor.ts                    |  13 +-
 packages/engine/src/index.ts                       |   6 +
 packages/engine/src/runtimes/in-process-runtime.ts |   8 +
 .../engine/src/workflow-authoritative-driver.ts    | 154 +++++++++++
 23 files changed, 686 insertions(+), 18 deletions(-)

Fusion-Task-Id: FN-5770
Fusion-Task-Lineage: dee668b5-10e0-4a3c-b025-9cc43a26286a
2026-06-07 18:51:46 -07:00
gsxdsm
294209f64b FN-5943: maintain tasks FTS5 indexes automatically
Keep the tasks FTS5 index compact and self-healing during routine maintenance.

- add FTS5 trigger helpers, index sizing utilities, and a schema migration that skips no-op searchable-field rewrites
- run merge/optimize/rebuild maintenance from self-healing with thresholds, cadence, and run-audit logging
- add focused FTS maintenance coverage and update storage/architecture docs for the new behavior

Files changed:
 docs/architecture.md                               |   1 +
 docs/storage.md                                    |  14 ++
 packages/core/src/__tests__/db-migrate.test.ts     |  50 ++--
 packages/core/src/__tests__/db.test.ts             |  84 +++----
 packages/core/src/__tests__/goals-schema.test.ts   |   2 +-
 packages/core/src/__tests__/insight-store.test.ts  |  10 +-
 .../src/__tests__/merge-request-record.test.ts     |   2 +-
 packages/core/src/__tests__/mission-store.test.ts  |   2 +-
 packages/core/src/__tests__/run-audit.test.ts      |   2 +-
 .../src/__tests__/store-archive-search.test.ts     |  33 +++
 .../core/src/__tests__/store-merge-queue.test.ts   |   2 +-
 packages/core/src/__tests__/task-documents.test.ts |   2 +-
 packages/core/src/archive-db.ts                    |   6 +-
 packages/core/src/db.ts                            | 162 ++++++++++---
 packages/core/src/store.ts                         |  16 ++
 .../engine/src/__tests__/fts-maintenance.test.ts   | 268 +++++++++++++++++++++
 packages/engine/src/self-healing.ts                |  70 ++++++
 .../src/store/__tests__/roadmap-store.test.ts      |   4 +-
 18 files changed, 622 insertions(+), 108 deletions(-)

Fusion-Task-Id: FN-5943

Fusion-Task-Lineage: 9a851ede-95ee-4b76-bc34-737912f0e3fc
2026-06-07 18:51:46 -07:00
gsxdsm
f49ab4946a Merge pull request #1463 from Runfusion/gsxdsm/issue-1455-initialize-git-repository
fix(FN-1455): initialize git during project registration
2026-06-06 01:08:31 -07:00
gsxdsm
db971a91ea fix(FN-1455): initialize git during project registration
Fusion-Task-Id: FN-1455
2026-06-06 00:38:28 -07:00
gsxdsm
841ff9d838 Address PR review feedback (#1461)
- pr-nodes: forward post-increment entity to deps.respond (responseRounds off-by-one); branch-group entity fallback now keys on task.branchContext.groupId, not task.id
- core: hoist shared autoMergeGateReason into @fusion/core pr-entity.ts; CLI + dashboard import the single definition (R13)
- cli: fn pr create also writes the unified PR entity (ensure → open), keeping legacy prInfo; resolveBranchHeadOid uses argv-safe execFileAsync (injection fix)
- changeset: fn-pr-commands bumped minor → major (breaking CLI removal per AGENTS.md)
- tests: bin.test.ts daemon fixture off reserved port 4040; lazy-loaded-views title 19 → 20 views

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-06 00:09:53 -07:00
gsxdsm
1922b5efc2 merge: main (workflow editor 109 / cli_sessions 110-111 / workflow_settings 112) — renumber PR-entity migration to 113, union core exports, TaskCard prNode + cliSessionState badges, executor PrNodeDeps + CliAgentRuntime options 2026-06-05 23:06:46 -07:00
gsxdsm
f1e9ab5587 fix(review): apply autofix feedback
Security hardening + cleanups from code review: parseAgentVerdicts now
ignores out-of-batch thread ids and fails safe (disagree) on conflicting
duplicate verdicts for one thread; drop the unused store param from
makePrResponseAgentRunner; correct the rework-bound doc (to-node, not
from-node) and the migration idempotency comment (PK is the re-run guard).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 22:49:39 -07:00
gsxdsm
3f313567dd feat(pr): built-in PR workflow template, end-to-end (U9)
Ships BUILTIN_PR_WORKFLOW_IR (builtin:pr-workflow) wiring the lifecycle
end to end: start -> pr-create -> await-review hold -> (changes-requested)
pr-respond -[rework]-> await-review -> (approved) auto-merge gate ->
pr-merge -> end, with conflict/failed holds and manual force-merge/close
edges. Completes U6's validator side: validateV2 permits a top-level
kind:rework edge whose loop-head opts in via config.reworkRegion (non-
rework cycles still rejected). Additive (default builtin:coding untouched);
behind workflowGraphExecutor. Legacy PrCommentHandler/PrMonitor retirement
deferred (they remain the flag-off path's PR handling) — recorded in the
plan. Fast e2e test; 41 core IR/builtin tests green.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 22:42:36 -07:00
gsxdsm
96f801c019 feat(pr): top-level bounded rework + auto-merge gate + legacy-bypass pin (U6)
Generalizes the foreach-only bounded-rework mechanism to the top-level
graph walk so the PR review loop (await-review -> pr-respond -> rework
back) is a legal bounded cycle: a kind:rework back-edge to a stacked node
returns a ReworkSignal the loop-head re-runs up to maxReworkCycles, then
routes outcome:rework-exhausted. Non-rework cycles still throw 'Cycle
detected' (safety preserved); foreach rework unchanged (shared core
constants). Adds createAutoMergeGateHandler (live entity re-fetch +
isPrEntityAutoMergeReady -> auto-on/auto-off). Pins R14: graph-executed
PR tasks merge through pr-merge, never the legacy queue. 122 graph tests
green.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 20:32:24 -07:00
gsxdsm
4e16145aab feat(pr): pr-create/pr-respond/pr-merge node kinds + handlers (U3)
Adds the three first-class PR workflow node kinds and their handlers via
createPrNodeHandlers(deps), registered in createDefaultNodeHandlers
(fail-closed pr-nodes-unwired when absent). GitHub ops are injected as
callbacks (PrNodeGithubOps) at all three CLI sites (daemon/serve/dashboard)
so the engine never imports the dashboard client (FN-3049). pr-create
routes open/failed as outcomes; pr-merge passes expectedHeadOid and never
writes 'merged' (reconcile corroborates); pr-respond delegates to an
injected respond callback (U5 fills the body). 10 tests.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 19:55:31 -07:00
gsxdsm
4ecf3e86fa feat(pr): PR entity foundation — schema v109, store CRUD, predicates (U1)
Adds the unified PR entity: pull_requests + pull_request_thread_state
tables (schema v109, re-runnable migration with three partial unique
indexes and a compat helper), PrEntity/PrThreadState types, store CRUD
(create-or-reuse, update, per-thread outcome upsert), and core-owned
predicates (isPrBacked merge-target-scoped, unverified hard gate,
auto-merge readiness). Migrates legacy branch_groups PR fields into
unverified entities (R19). Fixes the misleading 'transactional migration'
docstring.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 17:26:07 -07:00
gsxdsm
72e320aab4 Address PR review feedback (#1445)
- applyRemoteSettings now applies the stripped global payload (moved keys can't resurrect)
- resolver error path keeps effective workflowId so builtin fallback survives identity failure
- updateWorkflowSettingValues read-merge-upsert wrapped in transactionImmediate (lost-update race)
- MergeSection directMergeCommitStrategy UI fallback aligned to schema default (always-squash)
- save-split section-routing test asserts the positive case
- setting-values routes 404 on unknown workflow ids (+ tests)
2026-06-05 16:46:04 -07:00
gsxdsm
1f68348441 merge: main (CLI agent interface #1446) — renumber workflow_settings migration to 112 behind main's cli_sessions(110)/adapter(111), full-workspace literal sweep, i18n union 2026-06-05 16:18:39 -07:00
gsxdsm
693ed6290a Merge remote-tracking branch 'origin/main' into gsxdsm/cli-agent-interface
# Conflicts:
#	CONCEPTS.md
#	packages/core/src/__tests__/db-migrate.test.ts
#	packages/core/src/__tests__/db.test.ts
#	packages/core/src/__tests__/goals-schema.test.ts
#	packages/core/src/__tests__/insight-store.test.ts
#	packages/core/src/__tests__/merge-request-record.test.ts
#	packages/core/src/__tests__/mission-store.test.ts
#	packages/core/src/__tests__/run-audit.test.ts
#	packages/core/src/__tests__/store-merge-queue.test.ts
#	packages/core/src/__tests__/task-documents.test.ts
#	packages/core/src/db.ts
#	packages/dashboard/src/__tests__/agent-onboarding.test.ts
#	packages/dashboard/src/__tests__/ai-refine.test.ts
#	packages/dashboard/src/__tests__/chat-attachment-routes.test.ts
#	packages/dashboard/src/__tests__/experiment-routes.finalize.test.ts
#	packages/dashboard/src/__tests__/milestone-slice-interview.test.ts
#	packages/dashboard/src/__tests__/mission-interview.test.ts
#	packages/dashboard/src/__tests__/pr-metadata-generator.test.ts
#	packages/dashboard/src/__tests__/project-pause-resume-routes.test.ts
#	packages/dashboard/src/__tests__/routes-approval-sandbox-provisioning.test.ts
#	packages/dashboard/src/__tests__/routes-approval-secrets.test.ts
#	packages/dashboard/src/__tests__/routes-approval.test.ts
#	packages/dashboard/src/__tests__/routes-worktrunk.test.ts
#	packages/dashboard/src/__tests__/session-error-recovery.test.ts
#	packages/dashboard/src/__tests__/session-persistence-roundtrip.test.ts
#	packages/dashboard/src/__tests__/session-reconnect.test.ts
#	packages/dashboard/src/__tests__/session-resume-history.test.ts
#	packages/dashboard/src/__tests__/setup-routes.test.ts
#	packages/dashboard/src/__tests__/subtask-breakdown.test.ts
#	packages/dashboard/src/routes/__tests__/agent-avatar-routes.test.ts
#	packages/dashboard/src/routes/__tests__/custom-providers.test.ts
#	packages/dashboard/src/routes/__tests__/docker-node-routes.test.ts
#	packages/i18n/locales/en/app.json
#	plugins/fusion-plugin-roadmap/src/store/__tests__/roadmap-store.test.ts
2026-06-05 15:30:59 -07:00
gsxdsm
6d16c07197 merge: main (editor consolidation #1433, fast-tests, learnings) — renumber workflow_settings migration to 110, settings panel joins the sidebar disclosures, full-workspace literal sweep 2026-06-05 15:23:15 -07:00
gsxdsm
11fb9f1325 merge main: per-column agent assignment (binding validation, policy-escalation handshake, override notes) into workflow editor consolidation
Resolved 4 conflicts preserving both feature sets:
- WorkflowNodeEditor.tsx: kept card-node/edge/dialog/dirty-guard/auto-layout/
  onboarding/template/AI-edit features; wired main's columnAgentsEnabled flag
  gate, override-column agent registry load, and policy-escalation save retry
  (finishSave helper wraps both update payloads).
- WorkflowNodeEditor.test.tsx: kept U2/U4/AI-design describes plus main's U6
  column-agent describe; merged api mock + import lists.
- register-workflow-routes.ts: merged import sets (design DI seam + column-agent
  validators).
- agent-tools.ts: strip-approval-flags and column-agent binding assertion now
  both run in create/update tools.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 14:43:02 -07:00
gsxdsm
b7fa21c25e merge: main (column-agent assignment #1432) into workflow-settings — union executor/agent-tools/routes imports, both tool-description texts, both route helpers 2026-06-05 14:41:43 -07:00
gsxdsm
60f1b7fa39 Merge remote-tracking branch 'origin/main' into gsxdsm/cli-agent-interface
# Conflicts:
#	packages/dashboard/app/components/__tests__/ListView.test.tsx
2026-06-05 14:36:42 -07:00
gsxdsm
b8eea85dc9 Merge pull request #1432 from Runfusion/feat/column-agent-assignment
feat: per-column agent assignment for workflow columns
2026-06-05 14:19:53 -07:00
gsxdsm
59364e7c58 Address PR review feedback round 2 (#1432)
- R10 kill-switch: workflowColumns flag now gates the execution path (resolver
  installation + resume pass 2), making the documented rollback real
- resolver: skip parse candidates whose templateNodeId doesn't exist under the
  foreach (disambiguation guard)
- editor: reset the project-scoped agents cache on projectId change
- tests: kill-switch inertness, defer→own-settings release, candidate skip
2026-06-05 13:59:50 -07:00
gsxdsm
563cb5b372 Address PR review feedback (#1433)
- always dispose AI design session (try/finally) + rejecting-agent test
- prune expired design rate-limit entries per check
- apply workflowId precedence in createTaskWithReservedId
- compare-and-set migrated project default (no pre-transaction snapshot)
- reject fragment ids in setDefaultWorkflowId at the write boundary
- guard stripApprovalBypassFlags against malformed template nodes
- hoist duplicate stepToFragmentIr call in migration loop
- auto-layout preserves unplaced nodes (strictColumnForY)
- second same-pair connection births a failure edge for condition-capable sources
- insertFragment expands foreach templates into child nodes (lossless round-trip)
- copyIrWithFreshIds remaps namespaced foreach child layout keys
- discard stale AI-edit results after workflow switch
- i18n: returnEmptyString:false so empty locale placeholders fall back to en
- test fixes: schema-version titles, migrate idempotency assertion, TaskForm post-resolve + cross-mode regression, deterministic waits
2026-06-05 13:56:05 -07:00
gsxdsm
2a0223472e Address PR review feedback (#1432)
- delimiter-safe foreach instance-id resolution via IR-validated candidates
- restart watcher handles binding removal/defer-flip and re-keys the reverse
  heartbeat guard on agent change/delete
- governing-node stamp owned by the pass-initiating foreach instance (race fix)
- editor: policy-escalation confirm/retry handshake on save; foreach children
  inherit the override note; project-scoped agent fetches; picker disabled on
  registry fetch error; column-agent strings in the canonical i18n catalog
- tests: update-tool escalation surface, PATCH escalation route, parity bound
  to run-derived stages, try/finally cleanup, deterministic event waits,
  symmetric defer surfaces, binding-release regression
2026-06-05 09:29:04 -07:00
gsxdsm
79d6c6a667 fix(ci): resolve lint errors (useless-escape, prefer-const, unused param) 2026-06-05 03:56:29 -07:00
gsxdsm
b9afce306e fix(review): schema-version gate, output-filter escape-bypass, generic double-wrap, follow-up resolution
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 03:41:54 -07:00
gsxdsm
ace710633c feat(dashboard): cli-agent hybrid chat transcript with raw-terminal toggle (U12)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 02:38:38 -07:00
gsxdsm
6c9a81a05f fix(review): apply autofix feedback 2026-06-05 01:53:42 -07:00
gsxdsm
e208842606 chore: lint fixes and plan status flip to completed 2026-06-05 01:18:50 -07:00
gsxdsm
e2707afbd4 test(core): end-to-end workflow-settings journey + surface enumeration; docs and changeset 2026-06-05 01:16:27 -07:00
gsxdsm
a47ea3f7a1 fix(review): strip approval-bypass flags in agent workflow authoring for chat/planning lanes 2026-06-05 01:05:51 -07:00
gsxdsm
d05d5f575f fix(review): apply autofix feedback 2026-06-05 00:57:49 -07:00
gsxdsm
243113a3cf feat: cli-agent adapter settings, autonomy approval gate, and node editor config (U15)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 00:30:27 -07:00
gsxdsm
c1c99a9de0 feat(engine): wire cli-agent executor seam and task session lifecycle (U7)
Add `cli-agent` as a task-execute executor kind. A workflow node with
`config.executor === "cli-agent"` drives an engine-owned CLI coding agent
through the execute step via the new cli-agent/task-session.ts orchestration:
spawn in the worktree, issue the hook token + write hook scripts, inject the
prompt after readiness, subscribe to the state machine, and resolve on a
positive completion signal (R20 gating). Config is snapshotted at launch; the
PTY is reaped (completed) at the in-review handoff.

Executor seam: runGraphCustomNode gains a cli-agent branch delegating to
runCliAgentNode; the hard-cancel/abort path (awaitAbortInFlightTaskWork +
abortAllInFlight) claims and SIGKILLs the CLI session as a first-class surface,
marking it killed (never resume-eligible). Re-entry kills any prior live
session and launches fresh; follow-up resumes the recorded native session id
when supported. A PTY-pool ceiling surfaces as a typed task value, not a stall.

Node-config typing extended minimally (WorkflowNodeExecutorKind /
WorkflowNodeExecutorConfig in @fusion/core).

Tests: cli-agent/__tests__/task-session.test.ts (12) and
__tests__/cli-agent-executor.test.ts (9) cover AE1/AE5, hard cancel, re-entry,
follow-up, config snapshot, ceiling, and the generic-tier confirm-advance path,
using scripted adapters + a mock PTY seam. Engine typecheck clean; full
src/cli-agent suite + new tests green (144 passing).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 00:01:12 -07:00
gsxdsm
ef33d79e78 feat(core,dashboard): workflow-centric task creation with atomic workflowId materialization 2026-06-04 23:47:24 -07:00
gsxdsm
cb9a3f1cc5 feat(settings): surface sweep for the hard-move — export v2 with workflowSettings, sync moved-key filtering, CLI redirect hints, consistency guard 2026-06-04 23:41:30 -07:00
gsxdsm
e421774f6a feat(core): column agent IR schema, validation, and effective-agent resolver
U1+U2 of the column-agent plan: WorkflowColumnAgent on WorkflowIrColumn
(defer/override), template-subgraph column validation, v2-only-feature
registration, plugin-sdk type parity, and the shared core resolver with
instanceNodeId format ownership moved to core.
2026-06-04 23:35:32 -07:00
gsxdsm
4fe7dbe016 feat(core): one-time hard-move migration of workflow-policy settings to workflow setting values
30 moved keys (step execution, review/approval, per-phase model lanes) leave
DEFAULT_PROJECT_SETTINGS; marker-gated idempotent per-project migration writes
customized values to every in-use (workflowId, projectId); stale-writer guard;
tombstone allowlist derived from the builtin catalog.
2026-06-04 23:23:48 -07:00
gsxdsm
407ce03bf2 feat(dashboard): workflow and template JSON import/export with trust-boundary stripping 2026-06-04 23:16:46 -07:00
gsxdsm
202083dcff Merge U16: shared PTY native-asset loader in engine + redactSecrets in core 2026-06-04 22:54:01 -07:00
gsxdsm
ea18ef8d44 feat(engine): extract shared PTY native-asset loader and redactSecrets (U16)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-04 22:53:02 -07:00
gsxdsm
ad5205f186 feat(core): add cli_sessions table and CliSessionStore (U1)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-04 22:52:20 -07:00
gsxdsm
b1ebb22010 Merge current main (fast-tests quality-backfill projects) into plugin install fixes 2026-06-04 22:43:52 -07:00