Files
state-corp-backend/src/manage.py
Aleksandr Meshchriakov 697ecb7d1c
Some checks failed
CI/CD Pipeline / Code Quality Checks (push) Failing after 3m50s
CI/CD Pipeline / Run Tests (push) Successful in 3m57s
CI/CD Pipeline / Build Docker Images (push) Has been skipped
CI/CD Pipeline / Push to Gitea Registry (push) Has been skipped
CI/CD Pipeline / Deploy to Server (push) Has been skipped
Implement exchange imports and frontend reporting APIs
2026-04-07 16:31:04 +02:00

33 lines
928 B
Python

#!/usr/bin/env python
"""Django's command-line utility for administrative tasks."""
import os
import sys
STARTUP_CHECK_COMMANDS = {"runserver", "runserver_plus"}
def main():
"""Run administrative tasks."""
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "settings.dev")
try:
from django.core.management import execute_from_command_line
except ImportError as exc:
raise ImportError(
"Couldn't import Django. Are you sure it's installed and "
"available on your PYTHONPATH environment variable? Did you "
"forget to activate a virtual environment?"
) from exc
command = sys.argv[1] if len(sys.argv) > 1 else ""
if command in STARTUP_CHECK_COMMANDS:
from apps.core.startup_checks import run_startup_checks
run_startup_checks(component=command)
execute_from_command_line(sys.argv)
if __name__ == "__main__":
main()