Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

tt wait

Wait for an agent to reach a terminal state.

Synopsis

tt wait <AGENT> [--timeout <SECONDS>]

Description

Blocks until the specified agent reaches a terminal state (Stopped, Cold, or Error). Useful for scripting sequential workflows where you need to wait for an agent to finish before proceeding.

Arguments

ArgumentDescription
<AGENT>Agent name to wait for

Options

OptionDescription
--timeout <SECONDS>Maximum seconds to wait (default: wait forever)

Examples

Wait Forever

tt wait backend

Output:

⏳ Waiting for agent 'backend' to finish...
   Agent 'backend' reached state: 🛑 Stopped

Wait with Timeout

tt wait backend --timeout 300
# Waits up to 5 minutes

Scripted Workflow

tt spawn backend --role worker
tt assign backend "Build the API"
tt wait backend --timeout 600
tt spawn reviewer --role reviewer
tt assign reviewer "Review backend's work"
tt wait reviewer
echo "All done!"

See Also