Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
|
@@ -339,8 +339,8 @@ async def get_state():
|
|
| 339 |
# If the file is missing, attempt a download from HF as a fallback
|
| 340 |
download_state_file_from_hf()
|
| 341 |
if not os.path.exists(STATE_FILE_PATH):
|
| 342 |
-
|
| 343 |
-
|
| 344 |
|
| 345 |
try:
|
| 346 |
with open(STATE_FILE_PATH, "r") as f:
|
|
|
|
| 339 |
# If the file is missing, attempt a download from HF as a fallback
|
| 340 |
download_state_file_from_hf()
|
| 341 |
if not os.path.exists(STATE_FILE_PATH):
|
| 342 |
+
# If still not found (e.g., first run and 404 on HF), return default
|
| 343 |
+
return {"state": {"next_download_index": 0, "file_states": {}}}
|
| 344 |
|
| 345 |
try:
|
| 346 |
with open(STATE_FILE_PATH, "r") as f:
|