Localize notification_utils to the API

This changeset pulls in all of the notification_utils code directly into the API and removes it as an external dependency.  We are doing this to cut down on operational maintenance of the project and will begin removing parts of it no longer needed for the API.

Signed-off-by: Carlo Costino <carlo.costino@gsa.gov>
This commit is contained in:
Carlo Costino
2024-05-16 10:17:45 -04:00
parent 4cdf8b2cb2
commit 99edc88197
129 changed files with 49913 additions and 263 deletions

View File

@@ -14,6 +14,12 @@ from marshmallow import (
validates_schema,
)
from marshmallow_sqlalchemy import auto_field, field_for
from app import ma, models
from app.dao.permissions_dao import permission_dao
from app.enums import ServicePermissionType, TemplateType
from app.models import ServicePermission
from app.utils import DATETIME_FORMAT_NO_TIMEZONE, get_template_instance
from notifications_utils.recipients import (
InvalidEmailError,
InvalidPhoneError,
@@ -22,12 +28,6 @@ from notifications_utils.recipients import (
validate_phone_number,
)
from app import ma, models
from app.dao.permissions_dao import permission_dao
from app.enums import ServicePermissionType, TemplateType
from app.models import ServicePermission
from app.utils import DATETIME_FORMAT_NO_TIMEZONE, get_template_instance
def _validate_positive_number(value, msg="Not a positive integer"):
try: