bgStateLabel renders a background agent's coarse condition for user messages, e.g. "busy/working" while live or just "stopped" once exited.
(a *harness.BackgroundAgent)
| 566 | "task %q already has a %s session; --harness only selects the first session for an unbootstrapped task", |
| 567 | task.Slug, current.Name(), |
| 568 | ) |
| 569 | } |
| 570 | h, err := harnessByName(requested) |
| 571 | if err != nil { |
| 572 | return nil, fmt.Errorf("invalid --harness %q (available: %s)", requested, registeredHarnessNames()) |
| 573 | } |
| 574 | return h, nil |
| 575 | } |
| 576 | |
| 577 | // backgroundLauncherFor returns the harness's BackgroundLauncher |
| 578 | // capability, or a clean error if the harness can't host background |
| 579 | // sessions. This is the capability gate for $FLOW_TERM=bg: flow never |
| 580 | // silently falls back to a terminal tab when the pinned harness lacks |
| 581 | // the capability. |
| 582 | func backgroundLauncherFor(h harness.Harness) (harness.BackgroundLauncher, error) { |
no outgoing calls
no test coverage detected