Skip to content

Commit

Permalink
Model download status changed to IN_PROGRESS. Fixes download box disa…
Browse files Browse the repository at this point in the history
…ppear bug.
  • Loading branch information
dadmobile committed Dec 20, 2024
1 parent ccb58bf commit 56b678e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions transformerlab/shared/shared.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ async def async_run_python_script_and_update_status(python_script: list[str], jo
downloading a model.
This function runs a python script and updates the status of the job in the database
to RUNNING when the python script prints begin_string to stderr
to IN_PROGRESS when the python script prints begin_string to stderr
The FastAPI worker uses stderr, not stdout"""

Expand All @@ -108,7 +108,7 @@ async def async_run_python_script_and_update_status(python_script: list[str], jo
print(">> " + text)
if begin_string in text:
print(f"Job {job_id} now in progress!")
await db.job_update_status(job_id=job_id, status="RUNNING")
await db.job_update_status(job_id=job_id, status="IN_PROGRESS")

await process.wait()

Expand Down

0 comments on commit 56b678e

Please sign in to comment.