diff --git a/notifications/management/commands/notification_sender.py b/notifications/management/commands/notification_sender.py index a9bac23..3adbb70 100644 --- a/notifications/management/commands/notification_sender.py +++ b/notifications/management/commands/notification_sender.py @@ -1,20 +1,18 @@ import json import logging import time - from pathlib import Path + +from django.conf import settings from django.core.mail import EmailMultiAlternatives, get_connection from django.core.management import BaseCommand from slack_sdk import WebClient, errors -from database_locks import locked from notifications.models import Notification, Subscription -from django.conf import settings logger = logging.getLogger(__name__) -@locked class Command(BaseCommand): def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) diff --git a/setup.cfg b/setup.cfg index 64339be..f96a831 100644 --- a/setup.cfg +++ b/setup.cfg @@ -26,7 +26,6 @@ packages = find: python_requires = >=3.9 install_requires = Django >= 4.2, <6.0 - django-database-locks < 1 # tested with 2.3.0 and 3.0.0 django-templated-email >= 2.3, <4 html2text diff --git a/testapp/testapp/settings.py b/testapp/testapp/settings.py index 03b204f..67bf97b 100644 --- a/testapp/testapp/settings.py +++ b/testapp/testapp/settings.py @@ -37,7 +37,6 @@ 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', - 'database_locks', 'notifications', 'testapp', ] @@ -122,8 +121,6 @@ STATIC_URL = '/static/' -DATABASE_LOCKS_ENABLED = False - try: from .local_settings import * except ImportError: