Spaces:
Runtime error
Runtime error
Changed status decoding
Browse files
app.py
CHANGED
|
@@ -64,11 +64,11 @@ if submit_button and new_transactions:
|
|
| 64 |
# Keep checking status until it's no longer 'IN_QUEUE' or cancelled
|
| 65 |
status_url = f"{base_url}status/{st.session_state.job_id}"
|
| 66 |
st.session_state.job_status = "IN_QUEUE"
|
| 67 |
-
while st.session_state.job_status
|
| 68 |
status_response = requests.get(status_url, headers=headers)
|
| 69 |
status_data = status_response.json()
|
| 70 |
st.session_state.job_status = status_data.get('status', '')
|
| 71 |
-
if st.session_state.job_status
|
| 72 |
break
|
| 73 |
time.sleep(2) # Adjust interval as needed
|
| 74 |
|
|
|
|
| 64 |
# Keep checking status until it's no longer 'IN_QUEUE' or cancelled
|
| 65 |
status_url = f"{base_url}status/{st.session_state.job_id}"
|
| 66 |
st.session_state.job_status = "IN_QUEUE"
|
| 67 |
+
while st.session_state.job_status != "COMPLETED":
|
| 68 |
status_response = requests.get(status_url, headers=headers)
|
| 69 |
status_data = status_response.json()
|
| 70 |
st.session_state.job_status = status_data.get('status', '')
|
| 71 |
+
if st.session_state.job_status == "COMPLETED":
|
| 72 |
break
|
| 73 |
time.sleep(2) # Adjust interval as needed
|
| 74 |
|