discourse/config/initializers/000-active_record.rb
David Taylor 7d794f45b6
DEV: Move 'unknown OID' embeddings fix into core (#35519)
Having it in d-ai's plugin.rb file solves it when running plugin tests.
But when running core tests, plugins are not loaded, but the tables
still exist in the database.

Followup to 6247fdc255
2025-10-21 15:23:24 +01:00

10 lines
371 B
Ruby
Vendored

# frozen_string_literal: true
# No ActiveRecord for these models. Avoids the "unknown OID" warnings.
# We need it in core, because plugins are not loaded in core tests,
# but the tables are likely still present in the test database.
ActiveRecord.schema_cache_ignored_tables.push(
"ai_topics_embeddings",
"ai_user_embeddings",
"ai_document_fragments_embeddings",
)