aboutsummaryrefslogtreecommitdiff
path: root/webmentions_ssg/tasks/consumer.py
diff options
context:
space:
mode:
Diffstat (limited to 'webmentions_ssg/tasks/consumer.py')
-rw-r--r--webmentions_ssg/tasks/consumer.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/webmentions_ssg/tasks/consumer.py b/webmentions_ssg/tasks/consumer.py
index e53fce5..3bfe861 100644
--- a/webmentions_ssg/tasks/consumer.py
+++ b/webmentions_ssg/tasks/consumer.py
@@ -4,9 +4,18 @@ from .. import HUEY, create_app
def create_consumer() -> Huey:
+ """
+ Create and configure the Huey consumer.
+
+ The application is initialized, task modules are imported to register their
+ tasks, and the source scanner is registered with the configured periodic
+ schedule.
+
+ :return: Configured Huey instance.
+ """
app = create_app()
- from . import receiver, scanner, sender # noqa: E402, F401
+ from . import receiver, scanner, sender # noqa: F401
schedule = crontab(
*app.config["WEBMENTIONS_SSG_SCANNER_SCHEDULE"].split(), strict=True