JobData#

Module: iqm.iqm_server_client.models

class iqm.iqm_server_client.models.JobData(*, id: UUID, status: JobStatus, execution: JobExecution | None = None, compilation: JobCompilation | None = None, messages: list[JobMessage] = [], errors: list[JobError] = [], queue_position: int | None = None, timeline: list[TimelineEntry] = [])#

Bases: PydanticBase

Status, artifacts and metadata of a job.

Attributes

model_config

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

id

Unique ID of the job.

status

Current job status.

execution

Execution information for the job.

compilation

Compilation information for the job.

messages

Informational messages for the job.

errors

Errors for a failed job.

queue_position

Iff the status is JobStatus.WAITING, the number of jobs ahead of this job in the queue.

timeline

Server-side statuses reached by the job so far.

Methods

find_timeline_entry

Search the timeline for an entry matching the given criteria.

Parameters:
model_config: ClassVar[ConfigDict] = {'extra': 'ignore', 'ser_json_inf_nan': 'constants', 'validate_assignment': True, 'validate_default': True}#

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

id: UUID#

Unique ID of the job.

status: JobStatus#

Current job status.

execution: JobExecution | None#

Execution information for the job.

compilation: JobCompilation | None#

Compilation information for the job.

messages: list[JobMessage]#

Informational messages for the job.

errors: list[JobError]#

Errors for a failed job.

queue_position: int | None#

Iff the status is JobStatus.WAITING, the number of jobs ahead of this job in the queue. Otherwise None.

timeline: list[TimelineEntry]#

Server-side statuses reached by the job so far. May include statuses from several services.

find_timeline_entry(*, status: str, source: Literal['iqm-server', 'iqm-station-control'] | str | None = None) TimelineEntry | None#

Search the timeline for an entry matching the given criteria.

Parameters:
  • status (str) – Status of the searched timeline entry.

  • source (Literal['iqm-server', 'iqm-station-control'] | str | None) – Source of the searched timeline entry. If None, accepts any source.

Returns:

The first matching entry or None if the job timeline does not have any matching entries.

Return type:

TimelineEntry | None

Inheritance

Inheritance diagram of iqm.iqm_server_client.models.JobData