Spaces:
Runtime error
Runtime error
Download utils/init_supabase.py from Vinoth-46/YT-Automation: direct link, hf CLI and curl.
- Browser
- Download file 462 Bytes
-
https://huggingface.co/spaces/Vinoth-46/YT-Automation/resolve/main/utils/init_supabase.py
- Command line
-
hf download hf://spaces/Vinoth-46/YT-Automation/utils/init_supabase.py
-
curl -L -o init_supabase.py https://huggingface.co/spaces/Vinoth-46/YT-Automation/resolve/main/utils/init_supabase.py
462 Bytes
| import asyncio | |
| import os | |
| import sys | |
| # Add project root to path | |
| sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) | |
| from core.database import init_db | |
| async def main(): | |
| print("Initializing database on Supabase...") | |
| try: | |
| await init_db() | |
| print("Database initialized successfully!") | |
| except Exception as e: | |
| print(f"Failed to initialize database: {e}") | |
| if __name__ == "__main__": | |
| asyncio.run(main()) | |