This is a convenience function that handles the common case of running all jobs in a sweep with optional progress output and registry tracking.
Parameters
Name
Type
Description
Default
cli
JoshCLI
JoshCLI instance to use for execution.
required
job_set
JobSet
Expanded jobs to run.
required
registry
RunRegistry | None
Optional RunRegistry for automatic run tracking. If provided along with session_id, runs are automatically recorded.
None
session_id
str | None
Session ID for registry tracking (required if registry provided).
None
manage_status
bool
If True (default) and registry/session_id provided, automatically manage session status lifecycle: - Set status to “running” at start - Set status to “completed” if all jobs succeed - Set status to “failed” if any job fails or on exception Set to False for manual status control (e.g., API use cases).
True
remote
bool
If True, use run_remote() for cloud execution.
False
api_key
str | None
Josh Cloud API key (required if remote=True).
None
endpoint
str | None
Custom Josh Cloud endpoint URL.
None
on_complete
Callable[[ExpandedJob, Any], None] | None
Optional callback invoked after each job completes. Signature: callback(job, result) -> None. Called after registry recording (if enabled). Use for progress reporting, logging, etc.