Upload folder using huggingface_hub
Browse files
6.7.0/client/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
| 1 |
{
|
| 2 |
"name": "@gradio/client",
|
| 3 |
-
"version": "2.0.
|
| 4 |
"description": "Gradio API client",
|
| 5 |
"type": "module",
|
| 6 |
"main": "dist/index.js",
|
|
|
|
| 1 |
{
|
| 2 |
"name": "@gradio/client",
|
| 3 |
+
"version": "2.0.5",
|
| 4 |
"description": "Gradio API client",
|
| 5 |
"type": "module",
|
| 6 |
"main": "dist/index.js",
|
6.7.0/client/src/utils/submit.ts
CHANGED
|
@@ -237,12 +237,15 @@ export function submit(
|
|
| 237 |
time: new Date()
|
| 238 |
});
|
| 239 |
} else {
|
|
|
|
|
|
|
| 240 |
fire_event({
|
| 241 |
type: "status",
|
| 242 |
stage: "error",
|
| 243 |
endpoint: _endpoint,
|
| 244 |
fn_index,
|
| 245 |
message: output.error,
|
|
|
|
| 246 |
queue: false,
|
| 247 |
time: new Date()
|
| 248 |
});
|
|
@@ -464,11 +467,15 @@ export function submit(
|
|
| 464 |
});
|
| 465 |
close();
|
| 466 |
} else if (status !== 200) {
|
|
|
|
|
|
|
| 467 |
fire_event({
|
| 468 |
type: "status",
|
| 469 |
stage: "error",
|
| 470 |
-
broken:
|
| 471 |
-
message:
|
|
|
|
|
|
|
| 472 |
queue: true,
|
| 473 |
endpoint: _endpoint,
|
| 474 |
fn_index,
|
|
|
|
| 237 |
time: new Date()
|
| 238 |
});
|
| 239 |
} else {
|
| 240 |
+
const is_connection_error =
|
| 241 |
+
output?.error === BROKEN_CONNECTION_MSG;
|
| 242 |
fire_event({
|
| 243 |
type: "status",
|
| 244 |
stage: "error",
|
| 245 |
endpoint: _endpoint,
|
| 246 |
fn_index,
|
| 247 |
message: output.error,
|
| 248 |
+
broken: is_connection_error,
|
| 249 |
queue: false,
|
| 250 |
time: new Date()
|
| 251 |
});
|
|
|
|
| 467 |
});
|
| 468 |
close();
|
| 469 |
} else if (status !== 200) {
|
| 470 |
+
const is_connection_error =
|
| 471 |
+
response?.error === BROKEN_CONNECTION_MSG;
|
| 472 |
fire_event({
|
| 473 |
type: "status",
|
| 474 |
stage: "error",
|
| 475 |
+
broken: is_connection_error,
|
| 476 |
+
message: is_connection_error
|
| 477 |
+
? BROKEN_CONNECTION_MSG
|
| 478 |
+
: response.detail || response.error,
|
| 479 |
queue: true,
|
| 480 |
endpoint: _endpoint,
|
| 481 |
fn_index,
|