fleet-memory/hindsight-api/hindsight_api
Bjorn Schliebitz 6b78f7d949
fix(mcp): Chain MCP lifespan with FastAPI app lifespan (#81)
The MCP server's lifespan was not being properly chained with the
FastAPI app's lifespan, causing the MCP server to not start/stop
correctly when mounted as a sub-application.

Changes:
- Create MCP app before FastAPI app to access its lifespan
- Chain MCP lifespan context with FastAPI's lifespan context
- Ensures MCP server lifecycle is properly managed

This fix is required for the MCP server to function correctly when
used with Claude Code and other MCP clients.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-01 16:33:58 +01:00
..
alembic feat: extensions (#54) 2025-12-22 11:05:23 +01:00
api fix(mcp): Chain MCP lifespan with FastAPI app lifespan (#81) 2026-01-01 16:33:58 +01:00
engine feat(config): Add configurable observation thresholds (#83) 2026-01-01 16:22:25 +01:00
extensions feat: extensions (#54) 2025-12-22 11:05:23 +01:00
__init__.py feat: extensions (#54) 2025-12-22 11:05:23 +01:00
banner.py fix: doc build and lint files (#34) 2025-12-16 13:49:09 +01:00
config.py feat(config): Add configurable observation thresholds (#83) 2026-01-01 16:22:25 +01:00
daemon.py feat: refactor hindsight-embed architecture (#66) 2025-12-22 22:02:40 +01:00
main.py Load operation validator extension in main entry point (#72) 2025-12-23 15:47:26 +01:00
mcp_local.py feat: extensions (#54) 2025-12-22 11:05:23 +01:00
metrics.py fix: doc build and lint files (#34) 2025-12-16 13:49:09 +01:00
migrations.py feat: extensions (#54) 2025-12-22 11:05:23 +01:00
models.py feat: extensions (#54) 2025-12-22 11:05:23 +01:00
pg0.py feat: extensions (#54) 2025-12-22 11:05:23 +01:00
server.py fix: doc build and lint files (#34) 2025-12-16 13:49:09 +01:00