mqt.qudits.simulation.jobs.jobstatus

Module Contents

class JobStatus[source]

Bases: enum.StrEnum

Enumeration for job status.

INITIALIZING = 'initializing'
QUEUED = 'queued'
VALIDATING = 'validating'
RUNNING = 'running'
CANCELLED = 'cancelled'
DONE = 'done'
ERROR = 'error'
__str__() → str[source]

Return a human-readable description of the status.

property description: str

A detailed description of the job status.

classmethod from_string(status_str: str) → JobStatus[source]

Create a JobStatus from a string.

Parameters:

status_str (str) – The string representation of the status.

Returns:

The corresponding JobStatus enum.

Return type:

JobStatus

Raises:

ValueError – If the string doesn’t match any JobStatus.

property is_final: bool

Check if the status is a final state.

classmethod non_final_states() → list[JobStatus][source]

Return a list of all non-final states.

JOB_FINAL_STATES: set[JobStatus]
exception JobStatusError(message: str, status: JobStatus)[source]

Bases: Exception

Custom exception for JobStatus-related errors.

status