fix: use shared bound cron predicate
maintainer edit: make gateway execution, WebUI automation listing, and delete protection agree on the new bound cron shape. Legacy delivery payloads that carry sessionKey are excluded from the WebUI-bound automation surface.
This commit is contained in:
1 parent
b4b6c04657
commit
3725b42e0e
5 files changed
+43
-15
No files matched your search
@@ -14,6 +14,7 @@ from typing import Any, Callable, Coroutine, Literal
|
||||
from filelock import FileLock
|
||||
from loguru import logger
|
||||
|
||||
from nanobot.cron.automation import is_bound_agent_job
|
||||
from nanobot.cron.types import (
|
||||
CronJob,
|
||||
CronJobState,
|
||||
@@ -508,7 +509,7 @@ class CronService:
|
||||
return [
|
||||
job
|
||||
for job in self.list_jobs(include_disabled=include_disabled)
|
||||
if job.payload.kind == "agent_turn"
|
||||
if is_bound_agent_job(job)
|
||||
and job.payload.session_key == session_key
|
||||
]
|
||||
|
||||
|
||||
Reference in new issue
Block a user