shell_job_wait
Wait for a background shell job to finish and get its output without polling. If timeout expires, the job keeps running; call again or kill it.
Instructions
Block until a background job exits, then return its output.
Cheaper and more reliable than polling shell_job_output in a loop. If the
timeout expires the job keeps running and running comes back true — call
again or kill it.
Args: job_id: Id returned by shell_start. timeout: Max seconds to wait. The job is NOT killed on timeout. tail_lines: Return only the last N lines of each stream. 0 means all.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| job_id | Yes | ||
| timeout | No | ||
| tail_lines | No |