From 78fd82076489942c07aa83af09b6707f355970f2 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 8 Aug 2022 09:32:45 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- daphne/apps.py | 5 +++-- daphne/management/commands/runserver.py | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/daphne/apps.py b/daphne/apps.py index 3a566ea..de104db 100644 --- a/daphne/apps.py +++ b/daphne/apps.py @@ -1,12 +1,13 @@ # Import the server here to ensure the reactor is installed very early on in case other # packages import twisted.internet.reactor (e.g. raven does this). -import daphne.server # noqa: F401 - from django.apps import AppConfig from django.core import checks +import daphne.server # noqa: F401 + from .checks import check_daphne_installed + class DaphneConfig(AppConfig): name = "daphne" verbose_name = "Daphne" diff --git a/daphne/management/commands/runserver.py b/daphne/management/commands/runserver.py index 0ebde5f..b2fd2ee 100644 --- a/daphne/management/commands/runserver.py +++ b/daphne/management/commands/runserver.py @@ -33,7 +33,7 @@ def get_default_application(): value = getattr(module, name) except AttributeError: raise ImproperlyConfigured( - "Cannot find {!r} in ASGI_APPLICATION module {}".format(name, path) + f"Cannot find {name!r} in ASGI_APPLICATION module {path}" ) return value