From 968e1b4e4a6fbd5a15037cdb11a3f9dee5108570 Mon Sep 17 00:00:00 2001 From: Dennis Fink Date: Sat, 14 Nov 2026 18:44:23 +0100 Subject: docs(core): standardize reST docstrings Expand function and method documentation with consistent reST parameter, return, and exception fields while clarifying behavior where additional context is useful. Normalize test and migration docstrings to the same documentation conventions. --- webmentions_ssg/tasks/retention.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'webmentions_ssg/tasks/retention.py') diff --git a/webmentions_ssg/tasks/retention.py b/webmentions_ssg/tasks/retention.py index 86283b7..2c35cc7 100644 --- a/webmentions_ssg/tasks/retention.py +++ b/webmentions_ssg/tasks/retention.py @@ -20,6 +20,11 @@ def purge_old_received_webmentions() -> int: The status/time predicate is checked by the database in one DELETE, so a row recently requeued for verification is not purged based on a stale read. Outgoing sources and Webmentions are intentionally unaffected. + + Use the configured retention period and leave verified or in-progress rows + untouched. + + :returns: Number of expired terminal Webmentions removed. """ cutoff = datetime.now(UTC) - timedelta( days=current_app.config["RECEIVED_RETENTION_DAYS"] -- cgit v1.3.1