Canopydocs v0.4.7

The next action

Canopy answers one question per worktree: what would you do next here? It then offers that one thing as a button, with the reason sitting in front of it. Four surfaces render the same answer, so they can't drift apart:

  1. The button in the worktree bar, and .
  2. Each row of the overview.
  3. The Suggested section of the command palette.
  4. The attention queue, which stretches the idea across every worktree.

Priority order#

Evaluated top to bottom. First match wins.

#StateThe actionThe reason shownKind
1A service exited with an errorRestart <service>port <n> is down / the process exitedcrash
2An agent is waiting on a decisionAnswer agent<agent> needs a decisionurgent
3The worktree was never provisionedRun setupnever provisionedprimary
4A service is starting or stoppingStarting <service>waiting for the portbusy
5Behind originPull n commitsbehind origin — pull firstprimary
6Every service stoppedStart servicesN stoppedprimary
7Some services stoppedStart <service>N of M stoppedprimary
8An agent is workingAgent working…<agent> is editing filesbusy
9Ahead of origin with uncommitted workReview changesN ahead · uncommitted workprimary
10A web service is running on a portOpen :<port>everything healthycalm
11Nothing else appliesStart agenteverything healthycalm

Read down the list and you're reading the workflow. A crash blocks everything after it. A blocked agent means a machine is waiting on a human. An unprovisioned worktree isn't usable yet, and stale code shouldn't be booted. Review changes sits at the end of a session, and Open :port is a convenience rather than something you owe anyone.

Action styles#

KindAppearanceBehaviour
crashAccent fillRed is used for the problem. The button that fixes it stays constructive.
urgentAmberSomething is blocked on you.
primaryAccent fillThe ordinary next step.
busyMuted, disabledActing again would double-start it.
calmQuiet outlineOptional.

Pressing ⏎#

runs the next action. It stands down while a terminal, text field or dialog has focus, and while the action is busy. The button shows the hint when the binding is live, and not otherwise.

The attention queue#

The same idea, ranked across every worktree. The top bar's Needs you chip opens it:

The attention queue: crashes and failed background jobs first, then blocked agents, then completions.The attention queue: crashes and failed background jobs first, then blocked agents, then completions.
The attention queue: crashes and failed background jobs first, then blocked agents, then completions.
SeverityRowOffered action
0A background job failed (create, remove, migrate, reset, snapshot, export, restore)View, which opens the notice with the full error and log tail
0A service crashedRestart
1An agent is waitingAnswer
2Setup never ranRun setup
9A background job finishedDismiss

Crashes have no dismiss. They leave the queue by being fixed. Notices carry an ✕.

A failure notice is a detail, not a destination. The worktree it names might not exist any more if a create failed, so picking it opens the notice instead of navigating. Completions clear, and navigate only when the worktree is still there.

When nothing needs you the chip reads All clear and the popover says so.

Background jobs and notices#

Creating a worktree, removing one, and every database job can be dismissed while they run. The work belongs to the backend and carries on either way. But a dismissed dialog has nowhere to report back to, and an error that only ever existed inside it is an error you never see. An op whose dialog was sent away records its outcome as a notice, and the attention queue shows those next to crashes, since it's the place that already promises to hold everything needing a human.

The notice carries the full error text and the tail of the operation's log, untruncated, and the notice modal offers it for copying.

Two known gaps#

Both are wired end to end in the UI and waiting on the backend. They're called out here because the table above lists states you won't see yet.

Documentation for Canopy 0.4.7. Controls marked coming soon are present in the interface but have no implementation behind them yet.