datarobot_genai.drtools.workload.build_status
build_status
Artifact image-build status semantics shared by the workload tools.
Builds progress PENDING -> IN_PROGRESS -> BUILT -> COMPLETED (or FAILED).
BUILT and COMPLETED are sequential, not equivalent: BUILT means the image was
built locally but has NOT been pushed to the registry yet, so it is not
deployable — scheduling a workload on it fails with
422 runtime_image_uri ... None. Only COMPLETED is a green light. Some
flows (e.g. Code-to-Workload) report lowercase/dash-cased status variants
(pending / in-progress / completed), so statuses are normalized
before interpretation.
normalize_build_status
Uppercase and underscore a build status (in-progress -> IN_PROGRESS).
annotate_build_deployability
Return a copy of build with deployable and status_guidance attached.
Unrecognized statuses are returned unchanged rather than guessed at.
Source code in datarobot_genai/drtools/workload/build_status.py
raise_tool_error_for_workload_client_error
Map SDK errors like the shared helper, adding the BUILT-not-pushed 422 hint.