Spaces:
Running
Running
up
Browse files- predict.py +1 -1
predict.py
CHANGED
|
@@ -89,7 +89,7 @@ def predict(inputs, top_p, temperature, chatbot=[], history=[], system_prompt=''
|
|
| 89 |
response = requests.post(API_URL, headers=headers, proxies=proxies,
|
| 90 |
json=payload, stream=True, timeout=15)
|
| 91 |
except:
|
| 92 |
-
chatbot
|
| 93 |
yield chatbot, history, "Requests Timeout"
|
| 94 |
raise TimeoutError
|
| 95 |
|
|
|
|
| 89 |
response = requests.post(API_URL, headers=headers, proxies=proxies,
|
| 90 |
json=payload, stream=True, timeout=15)
|
| 91 |
except:
|
| 92 |
+
chatbot[-1] = ((chatbot[-1][0], 'Requests Timeout, Network Error.'))
|
| 93 |
yield chatbot, history, "Requests Timeout"
|
| 94 |
raise TimeoutError
|
| 95 |
|