qrisp.interface.Job.status#

abstractmethod Job.status() JobStatus[source]#

Query and return the current JobStatus of the job.

Typically this is a live query: it fetches the most up-to-date status available, which for remote backends may involve a network call. As a side effect, concrete implementations should store the result in _last_known_status before returning, so that last_known_status always reflects the most recently observed state.

Once a job has reached a terminal state (DONE, CANCELLED, or ERROR), that state cannot change again. Implementations may take advantage of this as an optimization and return the already-known terminal status without repeating the query.

Callers that want to avoid the cost of a live query can also read last_known_status directly. Call refresh() (or status()) when an explicit update is needed.

Returns:
JobStatus