apps/database/supabase/tests/description-table-hardening.sql is the
regression evidence. Each exception list in it is the exact current set, so a
new gap fails as an extra row and a closed gap fails as a missing row. The
lists only shrink.
Rules
Trigger-exempt tables
These tables were created after the strict-text resync without the generic trigger. Writes through their feature APIs are bounded by API validation and any table-specific CHECKs. Where RLS also lets clients write a table directly, only those CHECKs apply.task_templates carries the Tasks API limits as
named strict checks (slug 120, name and task name 1,024, description 10,000
characters). The description columns of hive_servers, hive_workflows and
hive_research_sessions accept platform-administrator writes with no length
limit. Attaching the trigger would apply generic limits that could reject
supported values, so each table needs a per-column limit review first.
Columns without named strict checks
On trigger-protected tables, the trigger enforces the strict limits for these columns, which were added after the resync:- Text:
calendar_auth_tokens.deactivated_reason,calendar_connections.access_role,meet_together_plans.timezone,onboarding_progress.guidance_mode,onboarding_progress.persona,onboarding_progress.replay_app,shortened_links.meet_link_kind,task_projects.ticket_key,transaction_categories.description,user_private_details.first_day_of_week,user_private_details.time_format,user_private_details.timezone,users.banner_url,workspace_calendar_events.sync_error,workspace_calendar_events.sync_status,workspace_cron_executions.endpoint_url,workspace_cron_executions.error,workspace_cron_executions.source,workspace_cron_jobs.endpoint_url,workspace_cron_jobs.external_app_id,workspace_cron_jobs.external_job_key,workspace_cron_jobs.http_method,workspace_cron_jobs.last_status,workspace_cron_jobs.locked_by,workspace_cron_jobs.schedule_timezone,workspace_habit_trackers.creation_key,workspace_quizzes.type. - JSON:
workspace_course_modules.vocabulary,workspace_cron_jobs.headers_config,workspace_quizzes.answer,workspace_quizzes.content.
users.handleandhandles.valuekeep the transaction-scoped administrator rename exception, which an unconditional CHECK cannot express.ai_chat_messages.contentuses the database-ownedai_chat_messages_content_length_checkand_bytes_check, because the table stays reachable through PostgREST.ai_chat_messages.metadatais exempt from payload limits.fee_lock_revisions.snapshotandhive_world_states.world_datalive on JSON-only tables with no text trigger.
Client-access tables
Each permissive policy is scoped to the row owner, workspace membership, a workspace permission, or a Hive member or platform administrator. The test pins every policy by table, name and command and rejects a predicate oftrue, so a
new or renamed policy, a changed command or an always-true predicate needs
review before it ships. Other predicate edits rely on code review.
Approved legacy-sized limits
workspace_calendar_events.descriptionandcrawled_urls.html: their strict limit is 10,000 characters and 40,000 bytes.ai_chat_messages.content: the database-owned 10,000-character and 40,000-byte limit.task_plan_items.notes: the 10,000-character note limit.task_templates.description: the 10,000-character Tasks API limit.workspace_external_project_page_versions.data: the 2 MiB page-version cap.