"""Entry point for the Task Management app.

Usage:
    python main.py

Configuration is read from environment variables (see .env.example). If a .env
file is present it is loaded automatically.
"""
from pathlib import Path

try:
    from dotenv import load_dotenv

    load_dotenv(Path(__file__).parent / ".env")
except ModuleNotFoundError:
    # python-dotenv may not be installed in the deployment environment.
    # Fall back to whatever is already present in the process environment.
    pass

from backend import create_app

app = create_app()
application = app

if __name__ == "__main__":
    app.run(host="127.0.0.1", port=8763, debug=False)
