Skip to main content
Retrieve the status of an async job. Use this after calling evaluations.run() in endpoint-connection mode to check whether the inference batch is still running, has completed, or has been cancelled.

Usage

    status = galtea.jobs.get_status(job_id=job_id)
    print(f"State:    {status.state}")
    print(f"Progress: {status.progress}")
    if status.error:
        print(f"Error:    {status.error}")
    if status.result:
        print(f"Result:   {status.result}")

Parameters

job_id
string
required
The ID of the job to inspect. Returned as jobId in the response from evaluations.run().

Returns

A JobStatus object with the following fields:
id
string
The job ID.
state
JobState
Current state of the job. One of: waiting, delayed, prioritized, waiting-children, active, completed, failed, cancelled.
progress
float | int | dict
Progress indicator published by the worker. Typically a percentage (0–100) or a custom object. Defaults to 0.
result
any
The job’s return value once it reaches completed state. None while in progress.
error
string
Error message if the job has reached failed state. None otherwise.

Errors

ErrorCause
EntityNotFoundExceptionThe job does not exist, or belongs to a different organization (the API returns 404 in both cases to avoid leaking cross-tenant existence).