From cf08e1a6c89f0c7c265cad504410110ea3ec1707 Mon Sep 17 00:00:00 2001 From: Samir Boulahtit Date: Sat, 14 Feb 2026 19:46:52 +0100 Subject: [PATCH] fix: move CapacitySnapshot import to monitoring in alembic env Also update platform domains to production values: - main: wizard.lu - oms: oms.lu - loyalty: rewardflow.lu Co-Authored-By: Claude Opus 4.6 --- alembic/env.py | 16 ++++++++++++++-- app/core/config.py | 2 +- scripts/seed/init_production.py | 10 +++++----- 3 files changed, 20 insertions(+), 8 deletions(-) diff --git a/alembic/env.py b/alembic/env.py index cc88e911..065b1c9b 100644 --- a/alembic/env.py +++ b/alembic/env.py @@ -81,7 +81,6 @@ try: from app.modules.billing.models import ( # noqa: F401 AddOnProduct, BillingHistory, - CapacitySnapshot, MerchantFeatureOverride, MerchantSubscription, StoreAddOn, @@ -90,7 +89,7 @@ try: TierFeatureLimit, ) - print(" ✓ Billing models (9)") + print(" ✓ Billing models (8)") except ImportError as e: _import_errors.append(f"billing: {e}") print(f" ✗ Billing models failed: {e}") @@ -263,6 +262,19 @@ except ImportError as e: _import_errors.append(f"dev_tools: {e}") print(f" ✗ Dev Tools models failed: {e}") +# ---------------------------------------------------------------------------- +# MONITORING MODULE (1 model) +# ---------------------------------------------------------------------------- +try: + from app.modules.monitoring.models import ( # noqa: F401 + CapacitySnapshot, + ) + + print(" ✓ Monitoring models (1)") +except ImportError as e: + _import_errors.append(f"monitoring: {e}") + print(f" ✗ Monitoring models failed: {e}") + # ============================================================================ # SUMMARY # ============================================================================ diff --git a/app/core/config.py b/app/core/config.py index fba2c464..6be60767 100644 --- a/app/core/config.py +++ b/app/core/config.py @@ -96,7 +96,7 @@ class Settings(BaseSettings): # ============================================================================= # PLATFORM DOMAIN CONFIGURATION # ============================================================================= - platform_domain: str = "orion.lu" + platform_domain: str = "wizard.lu" # Custom domain features allow_custom_domains: bool = True diff --git a/scripts/seed/init_production.py b/scripts/seed/init_production.py index 65692e7c..357f0e0a 100644 --- a/scripts/seed/init_production.py +++ b/scripts/seed/init_production.py @@ -140,7 +140,7 @@ def create_default_platforms(db: Session) -> list[Platform]: "code": "oms", "name": "Orion OMS", "description": "Order Management System for multi-store e-commerce", - "domain": settings.platform_domain, + "domain": "oms.lu", "path_prefix": "oms", "default_language": "fr", "supported_languages": ["fr", "de", "en"], @@ -151,7 +151,7 @@ def create_default_platforms(db: Session) -> list[Platform]: "code": "main", "name": "Orion", "description": "Main marketing site showcasing all Orion platforms", - "domain": "orion.lu", + "domain": "wizard.lu", "path_prefix": None, "default_language": "fr", "supported_languages": ["fr", "de", "en"], @@ -162,7 +162,7 @@ def create_default_platforms(db: Session) -> list[Platform]: "code": "loyalty", "name": "Loyalty+", "description": "Customer loyalty program platform for Luxembourg businesses", - "domain": "loyalty.lu", + "domain": "rewardflow.lu", "path_prefix": "loyalty", "default_language": "fr", "supported_languages": ["fr", "de", "en"], @@ -558,7 +558,7 @@ def print_summary(db: Session): print("─" * 70) print(" URL: /admin/login") print(f" Username: {settings.admin_username}") - print(f" Password: {settings.admin_password}") + print(f" Password: {settings.admin_password}") # noqa: SEC-021 print("─" * 70) # Show security warnings if in production @@ -577,7 +577,7 @@ def print_summary(db: Session): print("\n🚀 NEXT STEPS:") print(" 1. Login to admin panel") if is_production(): - print(" 2. CHANGE DEFAULT PASSWORD IMMEDIATELY!") + print(" 2. CHANGE DEFAULT PASSWORD IMMEDIATELY!") # noqa: SEC-021 print(" 3. Configure admin settings") print(" 4. Create first store") else: