Spaces:
Runtime error
Runtime error
lengyue233
commited on
Commit
•
d3adf53
1
Parent(s):
9bfe4ad
Fix error handling
Browse files
app.py
CHANGED
@@ -141,7 +141,7 @@ def inference(
|
|
141 |
|
142 |
if result == "done":
|
143 |
if payload["success"] is False:
|
144 |
-
|
145 |
break
|
146 |
|
147 |
codes.append(result)
|
|
|
141 |
|
142 |
if result == "done":
|
143 |
if payload["success"] is False:
|
144 |
+
return None, build_html_error_message(payload["error"])
|
145 |
break
|
146 |
|
147 |
codes.append(result)
|