Skip to content

Add workflow status center - #747

Open
onevcat wants to merge 7 commits into
mainfrom
feat/workflow-status-center-c1
Open

Add workflow status center#747
onevcat wants to merge 7 commits into
mainfrom
feat/workflow-status-center-c1

Conversation

@onevcat

@onevcat onevcat commented Aug 30, 2026

Copy link
Copy Markdown
Owner

Summary

  • add the selected-worktree workflow runtime indicator and native hover/pinned run panel
  • render deterministic run, role, step, repeat-round, instruction, and exhaustive attention-action state
  • route workflow attention/completion through typed reducer delegates, the existing notification pipeline, and completion toast
  • document the C1 contract, release gates, and CLI-facing behavior

Verification

  • make check
  • focused workflow/notification regression group: 107 tests
  • make test: 2,911 + 2 tests, zero failures
  • make build-app
  • make build-cli
  • make test-cli-smoke
  • make test-cli-unit: 233 tests
  • make test-cli-integration: 110 tests
  • isolated Debug visual verification in Normal, Shelf, and Canvas at normal and half-width window sizes

Release context

C1 is the final implementation slice in R2a. Adversarial review and reviewed-head live E2E remain explicit merge gates and will be recorded on this PR.

@onevcat

onevcat commented Aug 30, 2026

Copy link
Copy Markdown
Owner Author

Adversarial review round 1 disposition (head 31a9b590):

  • Fixed: selected-worktree workflow notices no longer equate selection with being viewed. Visibility is key-window aware, sidebar delivery still occurs, and the existing active-surface mute preference controls external delivery.
  • Fixed: attention from any active run is reflected in the toolbar while the newest run remains the primary summary.
  • Fixed: interaction with a hover-open panel pins it before menus/confirmations can outlive the pointer.
  • Fixed: toast priority now overlays a stable workflow popover identity instead of destroying pinned panel state.
  • Fixed: selected-worktree skipped and maxRoundsReached terminal outcomes show warning toasts.
  • Test-honesty fix: the duplicate-edge assertion now temporarily enables exhaustive TestStore checking.

All accepted fixes were introduced with failing regression tests before implementation. Verification on this head:

  • focused notification/presentation/App tests: 39 passed
  • duplicate-edge reducer regression: 1 passed with exhaustivity enabled
  • make check: passed
  • make build-app: passed, zero warnings/errors
  • make test: 2,915 + 2 tests in verified xcresults, zero failures

The installed Debug build and isolated CLI socket launch successfully. Visual automation of this exact follow-up head is still pending because the macOS UI bridge is currently failing with cgWindowNotFound / native-pipe closure; it remains part of the reviewed-head live E2E gate and is not being treated as passed.

@onevcat

onevcat commented Aug 30, 2026

Copy link
Copy Markdown
Owner Author

Adversarial review round 2 disposition (head c498bc23):

The reviewer independently traced all five round-1 fixes and ran 68 relevant tests plus strict SwiftLint. No P0/P1 or serious P2 remained; merge recommendation was positive pending reviewed-head live E2E.

I also accepted the three cheap P3 follow-ups before that gate:

  • an older attention run is now the default panel selection and VoiceOver label target while the newest run remains the compact summary;
  • the duplicate-edge test keeps TestStore exhaustivity enabled through the following cancel action, so a duplicate notice cannot be silently discarded;
  • docs/components/cli.md now describes the active-surface notification preference accurately.

The attention-run projection test was added first and failed to compile on the missing model seam, then passed after implementation. Both focused regressions pass; make check and make build-app are green with zero build warnings/errors.

@onevcat

onevcat commented Aug 30, 2026

Copy link
Copy Markdown
Owner Author

Adversarial review rounds 3 and 4 are complete on the final code head 7c235988.

  • Round 3 reviewed the attention-run selection/a11y and exhaustive-test delta: no P0/P1/P2; safe for live E2E.
  • Its two P3 residuals were fixed: popover close now clears sticky run selection, and notification docs distinguish pane-level ordinary notices from worktree-level workflow status notices.
  • Round 4 reviewed only that final delta: both changes passed, no P0/P1/P2, strict SwiftLint clean, 7c235988 explicitly approved as the reviewed E2E head.

Reviewed-head live E2E is in progress. While the macOS session is locked, the installed Debug build has already passed the display-sleep path: it launched, created a new terminal surface, executed a shell command with captured output, and launched a real Codex profile. A real workflow happy path completed with a persisted clean verdict. Live attention fixtures now cover both provisional variants, gone-role relaunch, and the full real watchdog interval (automatic nudge followed by 3-minute idle grace) with nudge / keep_waiting / skip / cancel exposed. Visual and control interaction checks remain intentionally pending until the session is unlocked.

@onevcat

onevcat commented Aug 31, 2026

Copy link
Copy Markdown
Owner Author

Reviewed-head live E2E found and fixed one material interaction regression in e301696e.

When the pinned panel's last active run finished, then a later run started in the same selected worktree, the toolbar status remained visible but could no longer open its popover until the worktree was reselected. The status button was conditionally removed at zero active runs, so its local presentation state did not reliably observe and reset across the transition.

The fix keeps WorkflowStatusPopoverButton mounted and gates only visibility/hit testing, allowing the empty-run transition to close and clear the popover before a later run appears.

Verification:

  • make check passed (76 checks).
  • WorkflowStatusCenterPresentationTests: 8 passed, 0 failed.
  • make build-app and make install-dev-build: 0 errors, 0 warnings.
  • Fresh installed Debug process: pinned provisional run -> accepted/completed -> active count zero -> toast dismissed -> new run in the same worktree -> the first toolbar click opened the new run panel without reselecting the worktree.

This final delta now needs the planned focused adversarial review before merge readiness.

@onevcat

onevcat commented Aug 31, 2026

Copy link
Copy Markdown
Owner Author

Final focused adversarial delta review for 7c235988..e301696e: PASS.

The reviewer traced the observed SwiftUI failure to destroying the button while its popover was mid-presentation. Keeping the control mounted lets the runs-empty transition close/reset that live instance before it re-presents for a later run.

No P0/P1/material P2 was found. The review specifically checked zero-run layout and hidden hit/accessibility targets, toast-over-pinned behavior, selection retention, worktree/mode transitions, close-task cleanup, and the single-principal-toolbar contract. Zero-run rendering remains zero-size, opacity zero, hit testing disabled, and Accessibility hidden; strict SwiftLint also passed.

Together with the rebuilt-app reproduction of the exact failure sequence, this delta is approved. Full local tests and final documentation/CI are the remaining mechanical gates.

@onevcat

onevcat commented Aug 31, 2026

Copy link
Copy Markdown
Owner Author

Final reviewed-head verification is complete; #747 is merge-ready once the current CI run passes.

Automated gates:

  • make check: passed (76 checks).
  • Final make test: 2,915 + 2 tests in the two result bundles, zero failures.
  • Focused final-delta suite: 8 passed.
  • make build-app / installed Debug build: zero errors, zero warnings.
  • CLI gates previously passed: build + smoke, 233 unit, 110 integration.

Adversarial review:

  • Five controlled rounds total.
  • The first round's five material findings were fixed and regression-covered.
  • The final focused round approved the live-found e301696e state-lifetime fix with no P0/P1/material P2.

Live E2E covered:

  • locked-session terminal surface creation, captured shell execution, and real Codex profile launch;
  • happy completion and persisted output/verdict;
  • concurrent runs, attention priority/count, hover preview and pinning;
  • Ask Again, Accept as Delivered, Accept with Verdict (clean), and native confirmation/menu survival;
  • real watchdog auto-nudge/idle grace, Nudge Again, Keep Waiting, and actual Skip;
  • gone-role relaunch (p22 -> p30) and actual Cancel with panes/outputs retained;
  • exact role-pane focus, Reveal Run Folder, Open Log, and background notification focus;
  • completion toast over a pinned panel with selection preserved;
  • Shelf/Default/Canvas, constrained width, and Accessibility labels/controls;
  • the exact zero-active -> later-new-run sequence on a freshly installed Debug app, proving the first toolbar click opens the panel after e301696e.

Temporary workflow definitions were removed, the isolated Debug app was stopped, and the durable record is updated in docs-ai/063-agent-workflows/010-c1-workflow-status-center.md at 07eae21b.

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