Spaces:
Sleeping
Sleeping
File size: 1,117 Bytes
d74c0dc |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
import os
from dotenv import load_dotenv
load_dotenv()
key = os.getenv("SUPABASE_SERVICE_KEY")
url = os.getenv("SUPABASE_URL")
print("Checking Supabase Configuration:")
print("=" * 50)
if key:
print(f"SUPABASE_SERVICE_KEY:")
print(f" Length: {len(key)} characters")
print(f" Starts with 'eyJ': {key.startswith('eyJ')}")
print(f" First 30 chars: {key[:30]}...")
print(f" Last 30 chars: ...{key[-30:]}")
if len(key) >= 200:
print(f" [OK] Key length is correct")
else:
print(f" [WARNING] Key might be too short (expected 200+)")
if key.startswith("eyJ"):
print(f" [OK] Key format looks correct (JWT)")
else:
print(f" [WARNING] Key doesn't start with 'eyJ'")
else:
print("SUPABASE_SERVICE_KEY: NOT SET")
print()
if url:
print(f"SUPABASE_URL:")
print(f" Value: {url}")
if url.startswith("https://") and ".supabase.co" in url:
print(f" [OK] URL format looks correct")
else:
print(f" [WARNING] URL format might be incorrect")
else:
print("SUPABASE_URL: NOT SET")
print()
print("=" * 50)
|