ovo.core.scheduler.base_scheduler

Module Contents

Classes

API

class ovo.core.scheduler.base_scheduler.SchedulerTypes
REGISTERED_CLASSES

None

classmethod register(name=None)
exception ovo.core.scheduler.base_scheduler.JobNotFound

Bases: Exception

class ovo.core.scheduler.base_scheduler.Scheduler(name: str, workdir: str, reference_files_dir: str, allow_submit: bool = True, submission_args: dict = None)

Bases: abc.ABC

IMPORTED_SCHEDULER_KEY: str

‘imported’

IMPORTED_JOB_ID: str

‘imported’

abstractmethod submit(pipeline_name: str, params: dict = None, submission_args: dict = None) str

Submits a workflow asynchronously and returns the PID.

Parameters:
  • pipeline_name – Workflow name and revision (ovo.rfdiffusion-end-to-end or github url with @version)

  • params – Dictionary of parameters to pass to the workflow.

  • submission_args – Submission arguments for the scheduler, overrides values in self.submission_args

Returns:

Scheduler job ID

abstractmethod get_status_label(job_id: str) str

Get human-readable job status label. Should NOT be used to determine job status.

abstractmethod get_result(job_id: str) bool | None

Get job result: True if successful, False if failed, None if still running.

abstractmethod get_log(job_id: str, task_id: str = None, preview: bool = False) str | None

Get job execution log

Parameters:
  • job_id – Scheduler job ID (DesignJob.job_id or DescriptorJob.job_id)

  • task_id – Task id of individual task (workdir for nextflow, task id for AWS Omics), None for entire job log

  • preview – Whether to return only the last 10 lines (INFO, WARN or ERROR only)

Returns:

Log string or None if not available

abstractmethod cancel(job_id)

Cancel job execution

abstractmethod get_output_dir(job_id: str)

Get job output path

abstractmethod get_job_start_time(job_id: str) datetime.datetime | None

Get job start time

abstractmethod get_job_stop_time(job_id: str) datetime.datetime | None

Get job end time

get_startup_time_minutes()

Get startup time of a task (in minutes)

wait(job_id: str, timeout: int = None, interval: int | float = 10) bool

Wait synchronously using sleep loop for job completion, with optional timeout.

Parameters:
  • job_id – Scheduler job ID

  • timeout – Maximum time to wait in seconds, None for no timeout

  • interval – Interval between status checks in seconds

Returns:

True if successful, False if failed, raises TimeoutError if timed out

abstractmethod get_pipeline_names() list[str]
get_param_schema(pipeline_name: str) dict | None

Get workflow schema JSON dict (JSON Schema standard) or None if not available.

get_failed_message(job_id)
supports_resume(job_id) bool
abstractmethod resume(job_id: str) str

Resume a failed or stopped job and return new job ID

Parameters:

job_id – Scheduler job ID to resume

abstractmethod get_tasks(job_id: str) pandas.DataFrame | None

Get job tasks as a DataFrame with columns: task_id, name, status, duration_seconds + custom columns from the scheduler

get_dag(job_id: str) str | None

Get a string representation of the job direct acyclic graph (DAG).

get_report(job_id: str) str | None

Read job execution report html as string.

get_timeline(job_id: str) str | None

Read job execution timeline html as string.