feat(scouts): register GmailConnector at startup

Adds GmailConnector registration to the FastAPI lifespan startup block,
making it available via the connector registry for the ScoutEngine
and any other startup-time consumers.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Roberto
2026-05-16 04:18:33 +02:00
parent c559754532
commit d1016fd65a

View File

@@ -79,6 +79,11 @@ async def _memory_cron_tick() -> None:
@asynccontextmanager
async def lifespan(app: FastAPI):
# Startup: register source connectors.
from app.scouts.connectors.gmail import GmailConnector # noqa: PLC0415
from app.scouts.connectors.registry import register_connector # noqa: PLC0415
register_connector(GmailConnector())
# Startup: ensure agent tool modules are loaded.
import app.agents # noqa: F401