deploy preflight: ai schema now has 5 tables (setup tab)
All checks were successful
Deploy production / deploy (push) Successful in 1m13s

This commit is contained in:
2026-10-26 09:23:35 +00:00
parent 8d2da984e0
commit 22279d181f

View File

@@ -188,8 +188,9 @@ try {
if (Number(stats.tables) !== STATS_TABLES || Number(stats.app_rw) !== STATS_TABLES)
throw new Error(`stats schema tables/grants are wrong: ${JSON.stringify(stats)}`);
// Private-by-default AI tracker (news public in the app; bots and usage owner-only): app role
// read/write, personal_ro none. 3 = news_items, bot_status, usage_entries.
const AI_TABLES = 3;
// read/write, personal_ro none. 5 = news_items, bot_status, usage_entries,
// provider_setup_providers, provider_setup_entries (setup tab, owner-only).
const AI_TABLES = 5;
const [ai] = await client`
select
count(*) filter (where has_table_privilege(c.oid, 'select, insert, update, delete')) as app_rw,