Skip to content

Implement Workflow Activity vNext - #3189

Merged
AbigailDeng merged 18 commits into
feat/2026-08-04_workflow-activity-vnextfrom
feat/2026-08-04_workflow-activity-vnext-implementation
Aug 6, 2026
Merged

Implement Workflow Activity vNext#3189
AbigailDeng merged 18 commits into
feat/2026-08-04_workflow-activity-vnextfrom
feat/2026-08-04_workflow-activity-vnext-implementation

Conversation

@AbigailDeng

@AbigailDeng AbigailDeng commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Problem and solution

Workflow Activity vNext needs a production implementation of the approved 17-frame design and UP-00 through UP-16 without changing existing console routes or inventing backend facts.

This PR adds an isolated workbench under /scopes/:scopeId/workflow-activity-vnext with real workflow creation/editing, receipt-bound draft observation, Activity summaries and detail, run recovery, account/settings surfaces, authentication reuse, and bilingual locale support.

The latest follow-up also audits the entire vNext user interface for backend concepts leaking into primary product copy:

  • Activity now presents workflow, product status, source, and update time without raw run IDs, state versions, read-model language, or query limits.
  • Run recovery, workflow creation/save, editor, catalogue, and settings errors use actionable product language; raw service errors and support identifiers are available only after opening Technical details.
  • Settings no longer exposes subject, scope, group, or runtime connection values by default.
  • Raw origin/status values are mapped to localized product labels.
  • Bundled template version metadata is not shown in the primary creation flow.
  • A reusable rule in apps/aevatar-console-web/AGENTS.md prevents runtime, transport, storage, consistency, raw-ID, and endpoint terminology from returning to default user surfaces.

All implementation and test changes are confined to apps/aevatar-console-web/. Existing Workflow, Run, Settings, Studio, Team, Login, Callback, redirect, session, menu, and locale routes are unchanged.

Real API and identity boundaries

  • Workflow drafts/editor use existing studioApi scoped draft, committed fallback, parse/serialize, save, and draft-run endpoints.
  • Activity uses the real observatory run summary/detail/graph endpoints.
  • Recovery uses POST /api/workflow/runs/fork; returned receipt identifiers stay diagnostic and are never treated as an observatory runId.
  • Settings/account/runtime use the existing user LLM, auth-session, and effective-runtime adapters.
  • memberId, workflowId, definitionActorId, publishedServiceId, runId, and fork receipt identities remain distinct.
  • Unsupported capabilities stay unavailable instead of using fixtures, demo rows, timers, localStorage authority, or success fallbacks.

Local verification

  • Focused copy and behavior tests: pnpm exec jest src/locales/catalog.test.ts src/pages/workflow-activity-vnext/activity/ActivityPage.test.tsx src/pages/workflow-activity-vnext/activity/RunDetailPage.test.tsx src/pages/workflow-activity-vnext/index.test.tsx --runInBand - 4 suites, 31 tests passed.
  • Dependency-selected related tests for the follow-up production files: 90 suites, 1068 tests passed. This was dependency-derived, not a bare full-suite command.
  • Changed-file static checks: pnpm exec biome check <16 explicit vNext files> - 16 files checked, no fixes needed.
  • Whitespace check: git diff --check - passed.
  • Design baseline: python3 docs/design-baselines/workflow-activity-vnext/verify-baseline.py - SHA 30e74d7b410ae72c4c91432355436679033679c54c10b1702908435b001577de, 17/17 frames, byte-identical generator output, PASS.
  • Full frontend suite, package-wide TypeScript, and production build were not rerun for this follow-up; GitHub CI owns full verification under the personal incremental frontend policy.

Real browser verification

Verified against the running frontend at http://localhost:5173 using the signed-in session and real remote backend data:

  • Activity loaded real run rows and showed only Workflow, Status, Source, and Updated columns.
  • Raw origins such as ad-hoc-chat and service-invoke rendered as Chat and Service; raw run IDs, state versions, read-model copy, and query-limit copy were absent.
  • Desktop 1440x1000, tablet 1024x900, and mobile 390x844 had no page-level horizontal overflow; mobile switched to a stacked activity layout.
  • Advanced settings kept runtime URLs hidden behind a closed Technical details disclosure.
  • AI defaults now accepts the real system-default response where routeKind is unspecified and the nullable modelSelection field is omitted; the signed-in browser session renders System default without a fallback.

Remaining backend capability gaps

  • Fork receipts provide newRunActorId, not an observatory runId; only general Activity navigation is safe.
  • Draft-run SSE provides no trustworthy observatory runId or stateVersion; stream end does not establish Activity completion.
  • Activity summaries do not provide duration, usage, outcome, revision, lineage, or lifetime totals.
  • Draft-only workflows may not expose definitionActorId; workflow filtering then remains explicitly unavailable.
  • No explicit publishedServiceId is available; Publish and published execution remain unavailable.
  • No identity conversion is inferred between member, workflow, definition, service, actor, or run IDs.

This PR remains intentionally Draft. It does not modify, ready, auto-merge, or merge design baseline PR #3187.

Table scrolling follow-up

  • Workflows, Activity, run Steps, and run Diagnostics now share a named, keyboard-focusable table scroll region.
  • Desktop and tablet tables own their vertical overflow and keep column headers sticky; the workbench page no longer acquires horizontal overflow from table content.
  • Long cell and request-parameter content wraps inside its column.
  • Mobile Workflows, Steps, and Diagnostics render as labeled stacked records; Activity retains its compact mobile record layout.

Focused verification for commit a0da670c8:

  • pnpm exec jest --findRelatedTests src/pages/workflow-activity-vnext/TableScrollRegion.tsx src/pages/workflow-activity-vnext/activity/ActivityPage.tsx src/pages/workflow-activity-vnext/activity/RunDetailPage.tsx src/pages/workflow-activity-vnext/styles.ts src/pages/workflow-activity-vnext/workflows/WorkflowsPage.tsx --runInBand - 3 suites, 24 tests passed.
  • pnpm exec biome check src/pages/workflow-activity-vnext/TableScrollRegion.tsx src/pages/workflow-activity-vnext/activity/ActivityPage.test.tsx src/pages/workflow-activity-vnext/activity/ActivityPage.tsx src/pages/workflow-activity-vnext/activity/RunDetailPage.test.tsx src/pages/workflow-activity-vnext/activity/RunDetailPage.tsx src/pages/workflow-activity-vnext/index.test.tsx src/pages/workflow-activity-vnext/styles.ts src/pages/workflow-activity-vnext/workflows/WorkflowsPage.tsx - 8 files checked, no fixes needed.
  • git diff --check - passed.
  • Real remote-data browser checks: desktop 1440x900, tablet 834x1112, mobile 390x844; no page-level horizontal overflow. Desktop sticky header position remained unchanged after scrolling the table to its maximum scrollTop=124; mobile used labeled stacked records without nested table scrolling.
  • Full frontend test, package-wide typecheck/lint, and production build were not run locally; GitHub CI owns full verification under the incremental frontend policy.

NyxID visual alignment (#3194)

This latest implementation supersedes the older mobile card/stacked-record styling notes above. The user paths, APIs, identity boundaries, authentication, localization, and real-data behavior remain unchanged.

  • Rebuilt the workbench shell around a 52px top bar and 200px desktop rail, with page titles inside the content surface and an accessible 240px mobile navigation drawer below 768px.
  • Applied AlibabaSans with NyxID's 28/28px desktop and 22/22px mobile title scale, 12/17px supporting copy, 32-36px controls, 8px maximum radius, Aevatar colors, and single-layer bordered sections.
  • Converted Workflows, Activity, Steps, and Diagnostics to 32px headers and 56px rows in semantic tables that keep horizontal and vertical overflow inside their named regions at every breakpoint.
  • Reworked New workflow into four equal creation choices; kept the editor canvas full-width with a compact Canvas/YAML control and a 32px locally scrollable mobile toolbar.
  • Reworked Run detail and Settings around 32px underline tabs; Settings now uses one bordered form container instead of a secondary side rail.
  • Preserved the branch's node inspector, save confirmation toast, direct draft deletion, canonical route builders, and authoritative save/materialization behavior.

Focused verification

  • pnpm exec jest --runInBand --runTestsByPath src/pages/workflow-activity-vnext/index.test.tsx src/pages/workflow-activity-vnext/activity/ActivityPage.test.tsx src/pages/workflow-activity-vnext/activity/RunDetailPage.test.tsx - 3 suites, 43 tests passed.
  • Final editor/catalogue rerun: pnpm exec jest --runInBand --runTestsByPath src/pages/workflow-activity-vnext/index.test.tsx - 1 suite, 32 tests passed.
  • pnpm exec biome lint src/app.tsx - changed application provider file passed without fixes.
  • pnpm exec biome check <12 explicit Workflow Activity vNext files> - 12 files checked, no fixes needed.
  • bash tools/ci/test_stability_guards.sh - passed.
  • bash tools/docs/lint.sh - 87 files checked, 0 errors.
  • python3 apps/aevatar-console-web/docs/design-baselines/workflow-activity-vnext/verify-baseline.py - SHA 30e74d7b410ae72c4c91432355436679033679c54c10b1702908435b001577de, 17/17 frames, byte-identical generator output, PASS.
  • git diff --check - passed.

Real browser evidence

Verified all vNext pages against the running signed-in app and real remote data at 1440x900, 834x1112, and 390x844.

  • Every viewport had document.documentElement.scrollWidth === clientWidth.
  • Desktop measured a 52px top bar, 200px rail, 28/28px title, 32px table header, and 56-57px rows.
  • Workflows displayed 12 real rows in a 558px local table viewport; Activity kept 75 real rows in a local 558px / 4232px scroll region.
  • Tablet tables measured 568px clientWidth / 720px scrollWidth with no page overflow; the editor title/actions did not overlap.
  • Mobile tables remained table-row semantics and measured 356px clientWidth / 720px scrollWidth; the 240px menu drawer opened correctly.
  • The mobile editor toolbar measured 358px clientWidth / 456px scrollWidth / 32px height, keeping overflow local.
  • Settings measured a 358px single container with 8px radius; Run detail tabs and its Steps table remained locally scrollable.

Full frontend tests, package-wide lint/typecheck, and the production build were not run locally under the incremental frontend policy. GitHub CI owns full verification.

Closes #3194

@AbigailDeng

Copy link
Copy Markdown
Contributor Author

Standalone workbench correction pushed in d879b88ba.

What changed:

  • Workflow Activity vNext now opts out of the global ProLayout chrome while retaining the existing auth/session/query/locale provider path.
  • The vNext workbench owns the full viewport and scroll container.
  • Tablet/mobile local navigation is horizontal.
  • Activity records switch to a bounded mobile card layout; long API-returned run IDs no longer overlap adjacent fields.

Focused verification:

  • pnpm jest --findRelatedTests src/app.tsx src/pages/workflow-activity-vnext/activity/ActivityPage.tsx src/pages/workflow-activity-vnext/styles.ts --runInBand -> 4 suites passed, 26 tests passed.
  • pnpm biome lint src/pages/workflow-activity-vnext/activity/ActivityPage.tsx src/pages/workflow-activity-vnext/styles.ts -> passed.
  • git diff --check -> passed before commit.
  • python3 apps/aevatar-console-web/docs/design-baselines/workflow-activity-vnext/verify-baseline.py -> SHA verified, 17/17 frames, generator byte-identical, PASS.

Real browser verification against the remote backend:

  • Desktop 1512x767: global ProLayout header/sider and MainLayout counts are 0; vNext root/rail counts are 1; language control count is 1.
  • Tablet 768x1024: table columns remain bounded and identifiers truncate within their cells.
  • Mobile 390x844: three local navigation items render in one row and Activity renders as record cards.
  • A real proxy failure displayed Activity unavailable with Retry; retrying the same request recovered the remote Activity data.

The full frontend suite, full typecheck, and production build were not run locally under the incremental frontend policy; GitHub CI owns full verification. A four-file Biome check was also attempted and reported existing whole-file formatting/import issues in src/app.tsx and src/app.layout.test.ts; those unrelated files were not mass-formatted.

@codecov

codecov Bot commented Aug 5, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 84.55%. Comparing base (8bfac95) to head (144b7dc).
⚠️ Report is 1 commits behind head on feat/2026-08-04_workflow-activity-vnext.

@@                             Coverage Diff                             @@
##           feat/2026-08-04_workflow-activity-vnext    #3189      +/-   ##
===========================================================================
- Coverage                                    84.56%   84.55%   -0.02%     
===========================================================================
  Files                                         1503     1503              
  Lines                                       140015   140015              
  Branches                                     17180    17180              
===========================================================================
- Hits                                        118409   118384      -25     
- Misses                                       13740    13765      +25     
  Partials                                      7866     7866              
Flag Coverage Δ
ci 84.55% <ø> (-0.02%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.
see 5 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@AbigailDeng

Copy link
Copy Markdown
Contributor Author

Settings layout refinement

Commit a8cf16983 corrects the vNext Settings presentation against the approved Excalidraw baseline and current web interface guidelines.

Problem and solution

  • Removed the legacy horizontal Ant Tabs presentation and replaced it with the baseline's desktop vertical settings navigation; tablet/mobile collapse to a horizontal secondary navigation.
  • Made the standalone vNext host fill the viewport so the dark navigation rail no longer leaves a bottom gap.
  • Constrained Settings content width and restored section hierarchy, field rows, responsive account facts, and a dirty-only sticky save bar.
  • Replaced the oversized dashed failure placeholder with a compact, actionable unavailable state. Retry still reads the same authoritative API; raw decoder details are available under an expandable Technical details disclosure.
  • Added visible link semantics, aria-current, live loading/error semantics, decorative icon treatment, safe-area spacing, bounded identifiers/URLs, and locale-aware expiry formatting.
  • Added all new copy to both en-US and zh-CN catalogues.
  • No mock/default fallback, localStorage authority, or generated server fact was added.

Local verification

  • Explicit changed tests: pnpm jest src/app.layout.test.ts src/pages/workflow-activity-vnext/index.test.tsx --runInBand - 2 suites, 21 tests passed.
  • Dependency-related tests: pnpm jest --findRelatedTests src/app.tsx src/locales/workflowActivityVNextMessages.en-US.ts src/locales/workflowActivityVNextMessages.zh-CN.ts src/pages/workflow-activity-vnext/WorkflowActivityVNextShell.tsx src/pages/workflow-activity-vnext/settings/SettingsPage.tsx src/pages/workflow-activity-vnext/styles.ts --runInBand - 90 suites, 1064 tests passed. This is dependency-derived, not a bare full-suite run.
  • Changed-file static checks: pnpm biome lint src/app.tsx src/app.layout.test.ts src/locales/workflowActivityVNextMessages.en-US.ts src/locales/workflowActivityVNextMessages.zh-CN.ts src/pages/workflow-activity-vnext/WorkflowActivityVNextShell.tsx src/pages/workflow-activity-vnext/index.test.tsx src/pages/workflow-activity-vnext/settings/SettingsPage.tsx src/pages/workflow-activity-vnext/styles.ts - 8 files checked, no issues.
  • Diff integrity: git diff --check and git diff --cached --check - passed.
  • Baseline verifier: SHA 30e74d7b410ae72c4c91432355436679033679c54c10b1702908435b001577de, 17/17 frames, byte-identical generator output, PASS.
  • Full frontend suite/typecheck/build for this incremental style commit: deferred to GitHub CI by personal local workflow policy.

Browser verification

  • Desktop 1512x823: vNext root fills viewport; document width 1512; no global ProLayout header/sider; no old Ant Tabs; one settings secondary nav; one active secondary link.
  • Tablet: horizontal settings secondary navigation verified.
  • Mobile 390x844: root and main width 390; no horizontal overflow; horizontal settings navigation; Account facts reduce to one column.
  • English Console locale renders expiry through Intl.DateTimeFormat, observed as Aug 5, 2026, 5:45 PM.
  • Screenshots captured for desktop, tablet, mobile, and Account states.

The remote AI settings response still fails authoritative DTO decoding because StudioUserLlmSettings.savedSelection.modelSelection is not an object. The UI now reports that honestly as unavailable with Retry and expandable technical details; it does not invent settings data.

PR #3189 remains Draft. Design baseline PR #3187 was not modified.

@AbigailDeng

Copy link
Copy Markdown
Contributor Author

Settings decode follow-up

The remote API represents the system default as savedSelection.routeKind = unspecified and omits the nullable modelSelection. The shared frontend adapter now normalizes only that exact state to { kind: unspecified }; non-default routes still require an explicit model-selection object. No mock or success fallback was added.

Focused verification

  • Regression test (red, then green): pnpm exec jest src/shared/studio/api.test.ts --runInBand - 1 suite, 59 tests passed after the fix.
  • Dependency-selected tests: pnpm exec jest --findRelatedTests src/shared/studio/api.ts --runInBand - 24 suites, 576 tests passed.
  • Focused lint: pnpm exec biome lint --skip=lint/correctness/noUnusedVariables src/shared/studio/api.ts src/shared/studio/api.test.ts - 2 files checked, no issues.
  • git diff --check - passed.
  • Real browser: signed-in Settings against the remote backend no longer shows AI defaults unavailable; it renders Preferred service with System default and has no page-level horizontal overflow.
  • The unfiltered biome check remains blocked by existing whole-file import/format drift and the pre-existing unused requestAccepted helper. Those unrelated files were not mass-formatted or refactored.
  • Full frontend suite, package-wide TypeScript, and production build were not run; GitHub CI owns full verification under the incremental frontend policy.

@AbigailDeng

Copy link
Copy Markdown
Contributor Author

Workflow and Activity filter alignment

Commit d82094688e86df45004c901c1cbe363cdbaa3e96 aligns the two list toolbars without inventing unsupported Workflow lifecycle states.

  • Workflows now offers only All workflows and Drafts; Draft membership comes from exact workflowId values returned by studioApi.listWorkflowDrafts(scopeId).
  • Activity keeps authoritative Run status and origin filters.
  • Both searches are URL-backed through q; Workflows uses view=drafts, while Activity preserves status, origin, definition, and workflowFilter.
  • A failed draft source disables Drafts in All workflows and renders an honest unavailable plus Retry state for an existing view=drafts URL.
  • Search is left-aligned, resource filters are right-aligned, Refresh is in the page header, and mobile controls are full width.

Focused local verification

  • pnpm exec jest src/pages/workflow-activity-vnext/index.test.tsx src/pages/workflow-activity-vnext/activity/ActivityPage.test.tsx src/locales/catalog.test.ts --runInBand - 3 suites, 29 tests passed.
  • pnpm exec jest --findRelatedTests src/pages/workflow-activity-vnext/workflows/WorkflowsPage.tsx src/pages/workflow-activity-vnext/activity/ActivityPage.tsx src/pages/workflow-activity-vnext/styles.ts src/locales/workflowActivityVNextMessages.en-US.ts src/locales/workflowActivityVNextMessages.zh-CN.ts --runInBand --verbose - dependency-selected tests exited 0.
  • pnpm exec biome check against the 7 changed TypeScript/style files - 7 files checked, no fixes required.
  • git diff --check - passed before commit.
  • python3 apps/aevatar-console-web/docs/design-baselines/workflow-activity-vnext/verify-baseline.py - SHA 30e74d7b410ae72c4c91432355436679033679c54c10b1702908435b001577de, frames 17/17, byte-identical generator output, PASS.

Real browser verification

Verified at http://localhost:5173 with the signed-in account and real remote backend data:

  • Desktop 1440x900: search 360px, resource filters 160px, no document or toolbar horizontal overflow.
  • Tablet 834x1112: both toolbars remain aligned with no horizontal overflow.
  • Mobile 390x844: search and every Select are 358px, matching the content width; no horizontal overflow.
  • Workflow search wrote q=weekly; selecting Drafts wrote view=drafts; reload restored both values.
  • Activity restored q, status, and origin from the copied URL.
  • Browser console contained no warnings or errors.

The full frontend suite, package-wide TypeScript/lint, and production build were not run locally under the machine-wide incremental frontend policy; GitHub CI owns full verification. PR #3189 remains Draft with no auto-merge. PR #3187 was not modified.

@AbigailDeng

Copy link
Copy Markdown
Contributor Author

Workflow Activity vNext user-path QA follow-up

Commit: 9f5526200

User-path result

  • UP-00: ProtectedRoute, sanitized returnTo, session restoration, account and locale actions verified with the existing real sign-in flow.
  • UP-01: authoritative Workflow browse/search/Drafts filtering and URL restoration verified.
  • UP-02: Describe reaches the real LLM route; remote account is blocked by 403 GROUP_NOT_ALLOWED. Input is preserved and no draft is fabricated.
  • UP-03: blank create reaches the real backend; backend rejects an empty steps list with 至少需要一个 step. No fake default step was inserted.
  • UP-04: invalid YAML stays editable with parser feedback; valid YAML created real draft fcaaccef17bc40ea825d4ec981ee7f03. Fixed editor materialization when the authoritative response contains YAML but omits an inline document.
  • UP-05: fixed bundled template field names to the backend contract; real draft 9925a325197344b9a10eeacde6e25ec7 materialized with both nodes.
  • UP-06: edit, validate, save, dirty state, Stay, and Discard verified; Publish remains honestly unavailable.
  • UP-07: real draft run streamed 25 updates; stream end directs the user to Activity without claiming final completion.
  • UP-08: the run appeared only after the authoritative Activity query returned it.
  • UP-09: search/status/source filters and reload restoration verified; workflow filtering uses exact definitionActorId.
  • UP-10: real run detail tabs verified. Raw upstream errors are now collapsed under Technical details.
  • UP-11: retry confirmation now identifies the exact failed step and preserves original input/run. Real fork request was blocked by remote Cloudflare 502; no fake run was inserted.
  • UP-12: sampled completed Chat and Service runs. Their graphs do not expose a root step identity usable for fork, so Run again remains disabled; no identity is guessed.
  • UP-13: real AI defaults read/save/discard/observation verified. NyxID Gateway remains a backend contract inconsistency: catalogue says ready, save rejects it as non-selectable.
  • UP-14: account status, NyxID method, and expiry use real data; unavailable profile fields stay unavailable; no secret is exposed.
  • UP-15: runtime values load from the real API and remain collapsed under Technical details.
  • UP-16: desktop real-session check completed. Current Chrome control cannot resize the signed-in tab; no mock auth/data was introduced to regenerate tablet/mobile functional screenshots.

Additional fixes from QA:

  • /api/user-config/* now proxies to the Studio host.
  • Changing creation methods clears stale failure/findings while preserving user input.
  • Built-in save locations no longer expose a scope UUID as product copy; all four creation methods show localized Default workspace.
  • Retry confirmation names the exact starting step.
  • Run and step errors use compact product language in the primary UI.

Local verification

  • Direct changed tests:
    pnpm exec jest src/pages/workflow-activity-vnext/index.test.tsx src/pages/workflow-activity-vnext/activity/RunDetailPage.test.tsx src/shared/config/proxyConfig.test.ts --runInBand
    • 3 suites, 38 tests passed.
  • Dependency-selected related tests:
    pnpm exec jest --findRelatedTests config/proxy.ts src/locales/workflowActivityVNextMessages.en-US.ts src/locales/workflowActivityVNextMessages.zh-CN.ts src/pages/workflow-activity-vnext/activity/RunDetailPage.tsx src/pages/workflow-activity-vnext/hooks/useWorkflowEditor.ts src/pages/workflow-activity-vnext/workflows/NewWorkflowPage.tsx src/pages/workflow-activity-vnext/workflows/workflowCreation.ts --runInBand
    • 90 suites, 1079 tests passed. The locale catalogues are global dependencies, so the dependency-derived set was broad; this was not a bare full-suite command.
  • Changed-file static checks:
    pnpm exec biome check config/proxy.ts src/locales/workflowActivityVNextMessages.en-US.ts src/locales/workflowActivityVNextMessages.zh-CN.ts src/pages/workflow-activity-vnext/activity/RunDetailPage.test.tsx src/pages/workflow-activity-vnext/activity/RunDetailPage.tsx src/pages/workflow-activity-vnext/hooks/useWorkflowEditor.ts src/pages/workflow-activity-vnext/index.test.tsx src/pages/workflow-activity-vnext/workflows/NewWorkflowPage.tsx src/pages/workflow-activity-vnext/workflows/workflowCreation.ts src/shared/config/proxyConfig.test.ts
    • 10 files checked, no fixes needed.
  • git diff --check: passed.
  • Design baseline verifier: SHA 30e74d7b410ae72c4c91432355436679033679c54c10b1702908435b001577de, 17/17 frames, byte-identical generator output, PASS.
  • Full frontend suite, package-wide typecheck, package-wide lint, and production build were not run locally. No repository-native affected typecheck is available; full verification is delegated to GitHub CI under the personal incremental frontend policy.

PR remains Draft. Design baseline PR #3187 was not modified.

@AbigailDeng

Copy link
Copy Markdown
Contributor Author

Incremental verification: committed-only editor fallback

Fix

  • Load committed-only editor source from GET /api/scopes/:scopeId/workflows?includeSource=true after the exact scoped draft GET returns 404.
  • Match only the exact API-returned workflowId.
  • Keep getPublishedWorkflow on the runnable scope-detail endpoint, so published-run eligibility is unchanged.

Local verification

  • Red/green regression: pnpm exec jest src/shared/studio/api.test.ts --runInBand -t "loads committed source from the scope list when a scoped draft is missing" — failed against the previous detail endpoint, then passed after the adapter fix.
  • Changed test file: pnpm exec jest src/shared/studio/api.test.ts --runInBand — 59 passed.
  • Related tests: pnpm exec jest --findRelatedTests src/shared/api/scopesApi.ts src/shared/studio/api.ts --runInBand — passed.
  • Changed-file lint: pnpm exec biome lint src/shared/api/scopesApi.ts src/shared/studio/api.ts src/shared/studio/api.test.ts — no errors; 1 pre-existing unused-function warning in src/shared/studio/api.ts:963.
  • Diff hygiene: git diff --check — passed.
  • Browser: reopened exact committed-only route workflow-24e16b86edc21d6fe9dfcf2900f419b5 in the authenticated Chrome session. It now opens the editor with the API-returned name instead of USER_WORKFLOW_NOT_READY. The backend returns no source YAML for this legacy item, so the UI honestly shows the empty-YAML state and keeps Run disabled.
  • Full frontend suite, full lint, typecheck, and production build: deferred to GitHub CI by personal local workflow policy.

Visual alignment follow-up was split to P2 issue #3194 and is not part of this commit.

@AbigailDeng

Copy link
Copy Markdown
Contributor Author

Functional verification update

Commit: 6078f9162 Complete Workflow Activity functional paths

Implemented

  • Workflow catalogue Delete is available only for API-returned drafts, confirms draft-only impact, treats DELETE 404 as already absent, refetches authoritative draft membership, and retains retry context on failure.
  • Workflow catalogue Run is available only for API-returned drafts and opens the exact scoped editor with ?run=1; the existing editor performs real YAML validation and does not auto-submit.
  • Committed-only rows no longer show a misleading disabled Run action.
  • vNext Settings filters user services unless the real model catalogue enumerates at least one model; Gateway remains available and historical unavailable selections remain preserved and disabled.
  • Default model is selectable only when the real catalogue provides model IDs; otherwise Settings honestly uses service-default or unavailable copy.
  • Dirty Settings navigation supports Stay, Discard and leave, and Save and leave. Save and leave waits until authoritative settings observation succeeds.
  • Added matching en-US and zh-CN copy.

Local verification

  • Changed test file: pnpm exec jest src/pages/workflow-activity-vnext/index.test.tsx --runInBand --detectOpenHandles -> 29/29 passed.
  • Changed-file static checks: pnpm exec biome check src/locales/workflowActivityVNextMessages.en-US.ts src/locales/workflowActivityVNextMessages.zh-CN.ts src/pages/workflow-activity-vnext/index.test.tsx src/pages/workflow-activity-vnext/navigation.ts src/pages/workflow-activity-vnext/settings/SettingsPage.tsx src/pages/workflow-activity-vnext/workflows/WorkflowEditorPage.tsx src/pages/workflow-activity-vnext/workflows/WorkflowsPage.tsx -> passed.
  • Design baseline: python3 apps/aevatar-console-web/docs/design-baselines/workflow-activity-vnext/verify-baseline.py -> PASS; SHA unchanged, 17/17 frames, generator byte-identical.
  • Dependency-related Jest expansion was stopped because shared locale catalogues expanded it toward the full frontend suite. No residual Jest process remains.
  • Full frontend suite, typecheck, and production build: delegated to GitHub CI by personal local workflow policy.

Real browser verification

Authenticated Chrome against the remote backend verified:

  • The previously failing committed-only 周报 Workflow opens in the editor; the API returned empty YAML and the UI honestly shows YAML content is empty with Run disabled.
  • Draft rows show Run and More actions; committed-only rows omit both Run and Delete.
  • Delete confirmation states that published versions and run history remain. No real delete was submitted.
  • Catalogue Run opened the exact draft URL with ?run=1 and displayed the existing Test run panel. No real run was submitted.
  • Settings real catalogue showed only System default and NyxID Gateway; unrelated user services were absent.
  • Desktop 1440x900, tablet 768x1024, and mobile 390x844 had no page-level horizontal overflow.

The remote proxy briefly returned ECONNRESET for workspace and draft requests during the first reload; a later retry loaded the same real Workflow successfully. PR remains Draft.

@AbigailDeng

AbigailDeng commented Aug 5, 2026

Copy link
Copy Markdown
Contributor Author

Workflow Studio canvas follow-up (136280404)

Problem and solution

The vNext editor mounted the existing WorkflowStudioCanvas, node library, and node inspector inside an extra non-flex wrapper. The canvas root relies on its parent flex sizing contract, so React Flow could initialize against a zero-height parent and render an empty band.

This follow-up adds a reusable WorkflowStudioCanvasRegion beside the existing Studio components and makes vNext consume that complete sizing surface:

  • fixed-height outer editor region;
  • explicit height: 100% flex viewport;
  • existing Studio canvas, Mini Map, controls, node library, and node inspector;
  • accessible localized canvas-region name.

The vNext workflowId route, real API loading, save/materialization, run, YAML, auth, locale, and identity logic are unchanged. The existing Team/member Workflow Studio route has no diff.

Local verification

  • TDD regression (observed failing before the fix, then passing):
    pnpm --dir apps/aevatar-console-web exec jest --runInBand --runTestsByPath src/pages/workflow-activity-vnext/index.test.tsx --testNamePattern 'renders loaded nodes inside the sized Workflow Studio canvas region'
  • Focused vNext route integration:
    pnpm --dir apps/aevatar-console-web exec jest --runInBand --runTestsByPath src/pages/workflow-activity-vnext/index.test.tsx - 30/30 passed.
  • Locale catalogue:
    pnpm --dir apps/aevatar-console-web exec jest --runInBand --runTestsByPath src/locales/catalog.test.ts - 7/7 passed.
  • Changed-file static checks:
    pnpm --dir apps/aevatar-console-web exec biome check src/pages/team-member-workflow-studio/components/WorkflowStudioCanvasRegion.tsx src/pages/workflow-activity-vnext/workflows/WorkflowEditorPage.tsx src/pages/workflow-activity-vnext/index.test.tsx src/locales/workflowActivityVNextMessages.en-US.ts src/locales/workflowActivityVNextMessages.zh-CN.ts - 5 files passed.
  • git diff --check - passed.
  • python3 docs/design-baselines/workflow-activity-vnext/verify-baseline.py - SHA 30e74d7b410ae72c4c91432355436679033679c54c10b1702908435b001577de, 17/17 frames, byte-identical generator, PASS.
  • Full frontend suite, package-wide typecheck/lint, and production build were not run locally; GitHub CI owns full verification under the personal incremental frontend policy.

Real browser evidence

Using the signed-in Chrome session, local frontend, and real remote backend:

  • incident_triage rendered 2 real nodes (classify, approve) plus the real edge, Mini Map, and controls.
  • Node selection opened the existing Studio inspector.
  • Add node opened the existing Studio node library.
  • YAML showed the real server-returned incident_triage source and switched back to Canvas without losing nodes.
  • Desktop: canvas region 1236 x 507, React Flow 1212 x 483.
  • Tablet fresh load: both nodes fit inside the 748 x 508 canvas region.
  • Mobile fresh load: canvas region 358 x 584, React Flow 334 x 560, 2 nodes, and document.scrollWidth === document.clientWidth === 390.

A forced reload exposed a transient React Flow zero-size initialization warning. The final explicit 100%-height flex viewport was added after that observation and is protected by the regression test above; the Chrome session had already been finalized, so a post-final-commit browser reload was not rerun locally.

PR #3189 remains Draft. PR #3187 was not modified.

@AbigailDeng

Copy link
Copy Markdown
Contributor Author

AI service inventory follow-up

Problem and solution

The vNext Settings page filtered user_service routes by model-catalog enumeration, which hid ready connected services whenever their model catalogue was not verifiable. The original Settings page treats service availability and explicit model enumeration as separate concerns.

This follow-up now passes the complete API routeOptions inventory through the shared buildUserLlmSelectionOptions contract. Ready and allowed services remain selectable even without an enumerated model list; those services use Provider default. System default now renders a stable Default model inheritance explanation, and the dirty-state action is labeled Restore saved settings / 恢复已保存设置 to state its effect precisely. No backend contract or endpoint changed.

Affected paths

  • apps/aevatar-console-web/src/pages/workflow-activity-vnext/settings/SettingsPage.tsx
  • apps/aevatar-console-web/src/pages/workflow-activity-vnext/index.test.tsx
  • apps/aevatar-console-web/src/locales/workflowActivityVNextMessages.en-US.ts
  • apps/aevatar-console-web/src/locales/workflowActivityVNextMessages.zh-CN.ts

Local verification

  • Related tests: pnpm --dir apps/aevatar-console-web exec jest --runInBand --runTestsByPath src/pages/workflow-activity-vnext/index.test.tsx - 1 suite, 32 tests passed.
  • Changed-file static checks: pnpm exec biome check src/pages/workflow-activity-vnext/settings/SettingsPage.tsx src/pages/workflow-activity-vnext/index.test.tsx src/locales/workflowActivityVNextMessages.en-US.ts src/locales/workflowActivityVNextMessages.zh-CN.ts - 4 files checked, no fixes needed.
  • Test stability guard: bash tools/ci/test_stability_guards.sh - passed.
  • Whitespace check: git diff --check -- <4 task files> - passed.
  • Design baseline: python3 apps/aevatar-console-web/docs/design-baselines/workflow-activity-vnext/verify-baseline.py - SHA 30e74d7b410ae72c4c91432355436679033679c54c10b1702908435b001577de, 17/17 frames, byte-identical generator output, PASS.
  • Full frontend suite, package-wide typecheck, and production build: deferred to GitHub CI by personal local workflow policy.

Design baseline

  • Primary design: apps/aevatar-console-web/docs/design-baselines/workflow-activity-vnext/aevatar-workflow-activity-vnext.excalidraw
  • Contract: apps/aevatar-console-web/docs/superpowers/specs/2026-08-04-workflow-activity-vnext-design.md
  • User paths: apps/aevatar-console-web/docs/superpowers/specs/2026-08-04-workflow-activity-vnext-user-paths.md
  • Authentication and localization reuse the existing Aevatar logic.
  • Production data comes only from real APIs and API-acknowledged user actions; no mock fallback was added.

Commit: 97011eb68

@AbigailDeng

Copy link
Copy Markdown
Contributor Author

Real browser verification for 97011eb68

Verified the local vNext Settings page at http://localhost:5173 with the existing signed-in Chrome session and real API data:

  • System default renders Default model with Uses the system-selected service and model.
  • Preferred service includes NyxID Gateway, Chrono LLM3, Chrono Sandbox, Chrono Storage Service, Firecrawl, and additional connected services instead of collapsing to Gateway only.
  • Selecting Chrono LLM3 renders the service-default model explanation and the dirty bar actions Restore saved settings and Save changes.
  • Restore saved settings returned the form to authoritative System default; no settings save request was submitted.

@AbigailDeng

Copy link
Copy Markdown
Contributor Author

Local verification

  • Related tests:
    • pnpm exec jest --runInBand --runTestsByPath src/shared/api/http/client.test.ts src/shared/api/scopeRuntimeApi.test.ts src/shared/api/workflowActivityApi.test.ts src/shared/studio/api.test.ts - 4 suites, 76 tests passed.
    • pnpm exec jest --runInBand --runTestsByPath src/pages/studio/components/bind/StudioMemberBindPanel.test.tsx - 1 suite, 14 tests passed.
    • pnpm exec jest --runInBand --runTestsByPath src/pages/runs/index.test.tsx - 1 suite, 20 tests passed.
    • Focused direct route/component files were also run individually: Studio page, Team detail/new/automations, Team Member Workflow Studio, Scope Service Runtime Workbench, Studio Build and Invoke panels.
    • pnpm exec jest --runInBand --silent --runTestsByPath src/pages/workflow-activity-vnext/activity/ActivityPage.test.tsx - 6 passed.
    • pnpm exec jest --runInBand --silent --runTestsByPath src/pages/workflow-activity-vnext/activity/runRecovery.test.ts - 4 passed.
    • pnpm exec jest --runInBand --silent --runTestsByPath src/pages/workflow-activity-vnext/hooks/useDraftMaterialization.test.ts - 3 passed.
    • pnpm exec jest --runInBand --silent --runTestsByPath src/pages/workflow-activity-vnext/hooks/useRunObservation.test.ts - 4 passed.
    • pnpm exec jest --runInBand --silent --runTestsByPath src/pages/workflow-activity-vnext/hooks/useWorkflowPublication.test.ts - 13 passed.
    • pnpm exec jest --runInBand --silent --runTestsByPath src/pages/workflow-activity-vnext/index.test.tsx - 67 passed.
    • pnpm exec jest --runInBand --runTestsByPath src/pages/workflow-activity-vnext/activity/RunDetailPage.test.tsx src/shared/config/proxyConfig.test.ts - 2 suites, 16 tests passed.
    • pnpm exec jest --runInBand --runTestsByPath src/pages/workflow-activity-vnext/workflows/WorkflowPublishDialog.test.tsx - 2 passed.
    • Settings save toast regression: red (no toast after observed save), then green with the shared toast emitted only after authoritative observation.
  • Changed-file static checks:
    • pnpm exec biome check --reporter=summary <81 explicit non-catalogue changed files> - passed.
    • pnpm exec biome check on the four final Settings/locale/test files - passed.
    • Both touched project message catalogues pass pnpm exec biome lint; their format divergence is inherited from HEAD, so no broad formatting rewrite was introduced.
    • git diff --check -- apps/aevatar-console-web and staged git diff --cached --check - passed.
  • Design baseline verifier:
    • python3 verify-baseline.py from docs/design-baselines/workflow-activity-vnext - declared SHA 30e74d7b410ae72c4c91432355436679033679c54c10b1702908435b001577de, 17/17 frames, byte-identical generator output: PASS.
  • Browser validation:
    • Not executed against this branch: the only running local frontend server is serving the main checkout on a different branch. No mock browser state was used as a substitute.
  • Full frontend suite, package-wide lint, typecheck, and production build: deferred to GitHub CI by the personal local frontend workflow policy.

@AbigailDeng
AbigailDeng marked this pull request as ready for review August 6, 2026 02:53
@AbigailDeng

Copy link
Copy Markdown
Contributor Author

CI fix validation for commit 144b7dc50:

  • CODEX_ALLOW_FULL_FRONTEND_VALIDATION=1 pnpm tsc - passed
  • pnpm exec jest src/pages/studio/index.test.tsx --runInBand --silent --json --outputFile=/tmp/aevatar-pr-3189-studio-jest.json - passed, 118/118
  • pnpm exec jest src/pages/scopes/components/ScopeServiceRuntimeWorkbench.test.tsx src/pages/studio/index.test.tsx src/pages/workflow-activity-vnext/index.test.tsx src/pages/workflow-activity-vnext/workflows/WorkflowPublishDialog.test.tsx --runInBand --silent --json --outputFile=/tmp/aevatar-pr-3189-ci-fix-jest.json - initially exposed one Studio route-persistence regression; the three other suites passed, and the Studio suite passed after the fix
  • pnpm exec biome check src/pages/scopes/components/ScopeServiceRuntimeWorkbench.tsx src/pages/studio/index.tsx src/pages/studio/index.test.tsx src/pages/workflow-activity-vnext/settings/SettingsPage.tsx src/pages/workflow-activity-vnext/workflows/WorkflowPublishDialog.tsx - passed
  • bash tools/ci/test_stability_guards.sh - passed
  • git diff --check - passed

The complete frontend test suite and production build were not run locally; GitHub CI owns those full checks.

@AbigailDeng
AbigailDeng merged commit fad9adf into feat/2026-08-04_workflow-activity-vnext Aug 6, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant