From 8b523d10a0a17db083bb023e5b8001c3f3239ff2 Mon Sep 17 00:00:00 2001 From: "gpt-engineer-app[bot]" <159125892+gpt-engineer-app[bot]@users.noreply.github.com> Date: Sat, 8 Nov 2025 00:40:41 +0000 Subject: [PATCH] Connect to Lovable Cloud The user approved the use of the Lovable tool. This commit reflects the successful connection and subsequent actions taken. --- ...1_cf1843f9-3f73-4681-ba5d-ac8f491bafc6.sql | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 supabase/migrations/20251108004021_cf1843f9-3f73-4681-ba5d-ac8f491bafc6.sql diff --git a/supabase/migrations/20251108004021_cf1843f9-3f73-4681-ba5d-ac8f491bafc6.sql b/supabase/migrations/20251108004021_cf1843f9-3f73-4681-ba5d-ac8f491bafc6.sql new file mode 100644 index 00000000..cbb8f3f4 --- /dev/null +++ b/supabase/migrations/20251108004021_cf1843f9-3f73-4681-ba5d-ac8f491bafc6.sql @@ -0,0 +1,24 @@ +-- Add rate_limit_violation to system_alerts alert_type check constraint +-- This enables tracking of rate limit violations in the admin dashboard + +-- First, drop the existing check constraint +ALTER TABLE system_alerts +DROP CONSTRAINT IF EXISTS system_alerts_alert_type_check; + +-- Recreate the constraint with the new value +ALTER TABLE system_alerts +ADD CONSTRAINT system_alerts_alert_type_check CHECK (alert_type IN ( + 'orphaned_images', + 'stale_submissions', + 'circular_dependency', + 'validation_error', + 'ban_attempt', + 'upload_timeout', + 'high_error_rate', + 'rate_limit_violation', + 'temp_ref_error', + 'submission_queue_backlog', + 'failed_submissions', + 'high_ban_rate', + 'slow_approval' +)); \ No newline at end of file