aistore.sdk.wait_result

View as Markdown

Module Contents

Classes

NameDescription
WaitResultResult of waiting for a job to reach a desired state.

API

class aistore.sdk.wait_result.WaitResult(
job_id: str,
success: bool,
error: typing.Optional[str] = None,
end_time: typing.Optional[datetime.datetime] = None
)
Dataclass

Result of waiting for a job to reach a desired state.

end_time
Optional[datetime] = None
error
Optional[str] = None
job_id
str
success
bool
aistore.sdk.wait_result.WaitResult.__bool__() -> bool

Returns True if wait operation was successful.

aistore.sdk.wait_result.WaitResult.from_snapshots(
job_id: str,
snapshots: typing.List[aistore.sdk.types.JobSnap]
)
classmethod

Create a WaitResult from a list of job snapshots.

Parameters:

job_id
str

The job ID

snapshots
List[JobSnap]

List of job snapshots from all target nodes

Returns:

WaitResult indicating success/failure based on snapshot states