Files
LabGraph/backend/config/settings/development.py
T

51 lines
1.3 KiB
Python

"""
Development settings for LabGraph.
Inherits all base settings and adds:
- DEBUG = True
- Relaxed CORS (localhost:3000 allowed by default)
- Console email backend
- Verbose DEBUG-level logging for apps and Celery
"""
from .base import * # noqa: F401, F403
from .base import env
DEBUG = True
CORS_ALLOWED_ORIGINS = env.list(
"CORS_ALLOWED_ORIGINS",
default=["http://localhost:3000", "http://127.0.0.1:3000"],
)
INTERNAL_IPS = ["127.0.0.1"]
EMAIL_BACKEND = "django.core.mail.backends.console.EmailBackend"
LOGGING = {
"version": 1,
"disable_existing_loggers": False,
"formatters": {
"verbose": {
"format": "[{levelname}] {asctime} {name}: {message}",
"style": "{",
},
},
"handlers": {
"console": {
"class": "logging.StreamHandler",
"formatter": "verbose",
},
},
"root": {
"handlers": ["console"],
"level": "INFO",
},
"loggers": {
"django": {"handlers": ["console"], "level": "INFO", "propagate": False},
"celery": {"handlers": ["console"], "level": "DEBUG", "propagate": False},
"apps": {"handlers": ["console"], "level": "DEBUG", "propagate": False},
"tasks": {"handlers": ["console"], "level": "DEBUG", "propagate": False},
},
}