Commit Graph

3 Commits

Author SHA1 Message Date
Agent Zero fcc1c92b33 fix: Migration 0104 — check table existence before ALTER, remove companies table 2026-08-04 22:42:25 +02:00
Agent Zero 6881e8abde fix: Add CREATE EXTENSION vector to migration 0104 2026-08-04 22:40:38 +02:00
Agent Zero 5d408934ba fix: Add Alembic migration 0104 for missing embedding + audit_log columns
Two critical bugs found by API integration tests:
1. contacts.embedding (vector(768)) — ORM model updated in Phase 5.3 but
   plugin migration 0002_embeddings.sql was never run as Alembic migration.
   Also adds embedding columns to mails, companies, files, calendar_entries, tags.
2. audit_log.created_at, updated_at, deleted_at — AuditLog inherits TenantMixin
   which expects these columns, but they were never added to the DB table.
   Also adds to deletion_log.

Migration uses IF NOT EXISTS checks for all columns/indexes.
Alembic head: 0103 → 0104
2026-08-04 22:39:07 +02:00