chore: add secret.py imports to settings/__init__.py

Ref. 4a17da5704
This commit is contained in:
Ethan Nguyen 2021-05-01 22:25:56 -04:00
parent 4a17da5704
commit 82899f28eb
No known key found for this signature in database
GPG Key ID: B4CA5339AF911920
2 changed files with 8 additions and 3 deletions

View File

@ -12,7 +12,7 @@ https://docs.djangoproject.com/en/3.2/ref/settings/
import logging import logging
import os import os
from pathlib import Path from pathlib import Path
from typing import List from typing import List, Optional
from django.contrib.messages import constants as messages from django.contrib.messages import constants as messages
@ -163,6 +163,11 @@ MESSAGE_TAGS = {
messages.ERROR: "danger", messages.ERROR: "danger",
} }
# Override the following in secret.py
SENIOR_GRAD_YEAR: int = -1
BRANDING_NAME: str = "UNDEFINED"
GLOBAL_MESSAGE: Optional[str] = None
try: try:
from .secret import * # noqa # pylint: disable=unused-import from .secret import * # noqa # pylint: disable=unused-import
except ImportError: except ImportError:

View File

@ -1,7 +1,7 @@
# Deployed senior graduation year
# e.g. if deploying in spring 2021, then 2021
from typing import List from typing import List
# Deployed senior graduation year
# e.g. if deploying in spring 2021, then 2021
SENIOR_GRAD_YEAR = 2021 SENIOR_GRAD_YEAR = 2021
# Branding name # Branding name