Skip to content

Commit

Permalink
fix cancel
Browse files Browse the repository at this point in the history
  • Loading branch information
genekogan committed Jan 14, 2025
1 parent e86ba52 commit e65f9df
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions eve/postprocessing.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
from eve.models import Model


def cancel_stuck_tasks():
async def cancel_stuck_tasks():
tasks = get_collection(Task.collection_name)

expired_tasks = tasks.find({
Expand All @@ -43,7 +43,7 @@ def cancel_stuck_tasks():

try:
tool = Tool.load(key=task.tool)
tool.cancel(task, force=True)
await tool.async_cancel(task, force=True)

except Exception as e:
print(f"Error canceling task {str(task.id)} {task.tool}", e)
Expand Down
1 change: 1 addition & 0 deletions remote_replicate_tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
modal.Image.debian_slim(python_version="3.11")
.apt_install("libmagic1", "ffmpeg", "wget")
.pip_install_from_pyproject(str(root_dir / "pyproject.toml"))
.run_commands(["playwright install"])
.env({"DB": db})
)

Expand Down

0 comments on commit e65f9df

Please sign in to comment.