Skip to content

Commit f0c98e4

Browse files
fix: throw error if build failed
1 parent 471aa5e commit f0c98e4

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/shared/backend/services/cloudbuild.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,11 @@ export const waitForJobSuccess = async (
122122
}
123123
updateStatus({ jobStatus: jobStatus.status, startedAt });
124124

125+
if (jobStatus.status === "BUILD_ERROR") {
126+
clearTimeout(timeoutId);
127+
throw new Error("Build failed");
128+
}
129+
125130
if (jobStatus.status === "BUILD_SUCCESS") {
126131
clearTimeout(timeoutId);
127132
return jobStatus;

0 commit comments

Comments
 (0)