Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -158,7 +158,7 @@ with gr.Blocks() as demo:
|
|
158 |
}
|
159 |
|
160 |
start_time = time.time()
|
161 |
-
with requests.post(API_URL, headers=HEADERS, data=json.dumps(data), stream=True) as r:
|
162 |
for response in r.iter_lines():
|
163 |
if len(response) > 0:
|
164 |
text = response.decode()
|
|
|
158 |
}
|
159 |
|
160 |
start_time = time.time()
|
161 |
+
with requests.post(API_URL, headers=HEADERS, data=json.dumps(data), stream=True, timeout=30) as r:
|
162 |
for response in r.iter_lines():
|
163 |
if len(response) > 0:
|
164 |
text = response.decode()
|