Properties
status
Status of this Job
Methods
wait_for_done
wait_for_done(
blocking_time_increment: float = 1.0, attempts: int = 20
)
Description
Wait for the job to be done.
Examples
job.wait_for_done()
Arguments
-
blocking_time_increment : Time between each attempts
-
attempts : Number of attempts
wait_for_status
wait_for_status(
statuses: Union[str, JobStatus, JobRunStatus, list[Union[str, JobStatus,
JobRunStatus]]], blocking_time_increment: float = 1.0, attempts: int = 20
)
Description
Wait for the job to be in a specific status.
Examples
job = client.get_job_by_id("job_id")
job.wait_for_status(JobStatus.SUCCESS)
Arguments
-
statuses : Status to wait for (JobStatus or JobRunStatus)
-
blocking_time_increment : Time between each attempts
-
attempts : Number of attempts
Returns
(JobStatus) or (JobRunStatus) of the job
update_job_run_with_status
update_job_run_with_status(
status: JobRunStatus
)
Description
Update the job run with a new status.
Examples
job.update_job_run_with_status(JobRunStatus.SUCCEEDED)
Arguments
- status : New status of the job run
send_logging
send_logging(
log: Union[str, list], part: str, final: bool = False, special: Union[str, bool,
list] = False
)
Description
Send a log entry to the job.
Examples
job.send_logging("log1", "part1")
job.send_logging("log2", "part1")
job.send_logging("log3", "part2")
job.send_logging("log4", "part2", final=True)
Arguments
-
log (str) : Log content
-
part (str) : Logging Part
-
final (bool, optional) : True if Final line. Defaults to False.
-
special (bool, optional) : True if special log. Defaults to False.
start_logging_chapter
start_logging_chapter(
name: str
)
Description
Start a logging chapter.
Examples
job.start_logging_chapter("chapter1")
job.send_logging("log1")
job.send_logging("log2")
job.end_logging_chapter()
Arguments
- name (str) : Chapter name
start_logging_buffer
start_logging_buffer(
length: int = 1
)
Description
Start a logging buffer.
Examples
job.start_logging_buffer()
job.send_logging("log1")
job.send_logging("log2")
job.end_logging_buffer()
Arguments
- length (int, optional) : Buffer length. Defaults to 1.
end_logging_buffer
end_logging_buffer()
Description
End the logging buffer.
store_logging_file
store_logging_file(
path: Union[str, Path]
)
Description
Store a logging file in the platform.
Examples
job.store_logging_file("path/to/file")
Arguments
- path (str or Path) : path to the file or folder.
Raises
- FileNotFoundException : No file found at the given path
Returns
Object name of logging file as string