remove fallback onto ASGIHandler

ASGIHandler is considered a django internal api with get_asgi_application being the public counterpart.
get_asgi_application is also present since the introduction of django's asgi support so the ImportError should never occur anyways.
This commit is contained in:
Finn-Thorben Sell 2021-09-09 15:01:11 +02:00
parent 1ada7d14f7
commit c1cb3874f2
No known key found for this signature in database
GPG key ID: A78A03C25A3A3825

View file

@ -2,13 +2,7 @@ from . import importer
importer.install()
try:
from django.core.asgi import get_asgi_application
except ImportError: # pragma: no cover
from django.core.handlers.asgi import ASGIHandler
def get_asgi_application(): # noqa
return ASGIHandler()
from django.core.asgi import get_asgi_application
# this is just for the crazy ones
application = get_asgi_application()