mirror of
https://github.com/langbot-app/LangBot.git
synced 2026-06-09 23:36:02 +00:00
feat: preliminarily implement pipeline invoking
This commit is contained in:
@@ -233,3 +233,10 @@ class AsyncTaskManager:
|
||||
if not wrapper.task.done() and scope in wrapper.scopes:
|
||||
|
||||
wrapper.task.cancel()
|
||||
|
||||
def cancel_task(self, task_id: int):
|
||||
for wrapper in self.tasks:
|
||||
if wrapper.id == task_id:
|
||||
if not wrapper.task.done():
|
||||
wrapper.task.cancel()
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user