From d0e245d63e014d268310976fc45429f08d2cbbe9 Mon Sep 17 00:00:00 2001 From: Dennis Fink Date: Wed, 19 Aug 2026 19:49:55 +0200 Subject: refactor(core): improve typing and test coverage Restructure database and user CLI commands, make passwords write-only model properties, and use the UTC datetime constant throughout the application. Add PEP 287-style documentation and expand receiver, scanner, sender, and URL security tests to cover error paths and edge cases. --- webmentions_ssg/tasks/consumer.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'webmentions_ssg/tasks/consumer.py') 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 -- cgit v1.3.1