The retain outbox callback was passing context.tenant_id (raw UUID like 0f3ad4ec-8b88-...) instead of the PostgreSQL schema name (tenant_0f3ad4ec_...). This caused the webhook manager to query a non-existent schema, triggering a PostgreSQL error that silently aborted the entire retain transaction — rolling back all inserted memory data with no clear indication of data loss. Fixed both the async worker path (memory_engine.py) and sync HTTP path (http.py) to use _current_schema.get() which holds the correct tenant-prefixed schema name. Also changed fire_event_with_conn to re-raise exceptions instead of swallowing them, since errors inside a caller's transaction poison it irreversibly. |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| http.py | ||
| mcp.py | ||