Commit
·
70c3f35
1
Parent(s):
880c8df
addin warning if pull failed
Browse files
app.py
CHANGED
|
@@ -170,10 +170,14 @@ with st.sidebar:
|
|
| 170 |
stderr=subprocess.PIPE,
|
| 171 |
text=True, # Decode stdout/stderr as text
|
| 172 |
)
|
| 173 |
-
st.
|
| 174 |
process.wait()
|
| 175 |
process.kill()
|
| 176 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 177 |
# If a user has the right perms, then this clears the cache
|
| 178 |
load_results.clear()
|
| 179 |
get_volume.clear()
|
|
|
|
| 170 |
stderr=subprocess.PIPE,
|
| 171 |
text=True, # Decode stdout/stderr as text
|
| 172 |
)
|
| 173 |
+
st.info(f"Background task started with PID: {process.pid}")
|
| 174 |
process.wait()
|
| 175 |
process.kill()
|
| 176 |
+
# stdout, stderr = process.communicate()
|
| 177 |
+
if process.returncode != 0:
|
| 178 |
+
st.error("The process did not finish successfully.")
|
| 179 |
+
else:
|
| 180 |
+
st.success(f"PID {process.pid} finished!")
|
| 181 |
# If a user has the right perms, then this clears the cache
|
| 182 |
load_results.clear()
|
| 183 |
get_volume.clear()
|