# import sys
# import os
# import logging

# # ----------------------------
# # 1. Set up logging for debugging
# # ----------------------------
# logging.basicConfig(level=logging.DEBUG)
# logger = logging.getLogger(__name__)
# logger.debug("Starting Passenger WSGI app...")

# # ----------------------------
# # 2. Use the virtual environment
# # ----------------------------
# INTERP = "/home/mockexerciseeure/public_html/asma/venv/bin/python"
# if sys.executable != INTERP:
#     os.execl(INTERP, INTERP, *sys.argv)

# # ----------------------------
# # 3. Add app directory to path
# # ----------------------------
# app_dir = os.path.dirname(__file__)
# sys.path.insert(0, app_dir)
# logger.debug(f"App directory added to sys.path: {app_dir}")

# # ----------------------------
# # 4. Import Flask app
# # ----------------------------
# try:
#     from main import app as application
#     logger.debug("Flask app imported successfully")
# except Exception as e:
#     logger.exception("Failed to import Flas

