aboutsummaryrefslogtreecommitdiff
path: root/tests/cli
diff options
context:
space:
mode:
authorDennis Fink2026-10-30 13:24:53 +0100
committerDennis Fink2026-10-30 13:24:53 +0100
commitf6d96df2c3aecb51ca97426efddb101dce6350d7 (patch)
tree2968f65a627fbfd15051277d07eaa321db0e3cc4 /tests/cli
parent2b59a3082000842d980f9e19931949dbe5011229 (diff)
downloadwebmentions-ssg-f6d96df2c3aecb51ca97426efddb101dce6350d7.tar.gz
webmentions-ssg-f6d96df2c3aecb51ca97426efddb101dce6350d7.zip
feat(sender): add persistent retry backoff
Persist retry state per source revision so temporary delivery failures survive worker restarts and duplicate queued tasks cannot bypass the retry schedule. Use capped exponential backoff, stop after a configurable attempt limit, and reset the retry budget when a source changes or an admin resends manually.
Diffstat (limited to '')
-rw-r--r--tests/cli/test_database.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/cli/test_database.py b/tests/cli/test_database.py
index 51b79ac..f25aade 100644
--- a/tests/cli/test_database.py
+++ b/tests/cli/test_database.py
@@ -80,8 +80,11 @@ def test_create_db_builds_schema_and_records_latest_migration(
assert _database_revision(database_app) == _head_revision(database_app)
with database_app.app_context():
- table_names = set(inspect(DATABASE.engine).get_table_names())
+ inspector = inspect(DATABASE.engine)
+ table_names = set(inspector.get_table_names())
+ columns = {column["name"] for column in inspector.get_columns("sent_webmentions")}
assert {"alembic_version", "users", "received_webmentions"} <= table_names
+ assert {"attempt_count", "next_retry_at"} <= columns
def test_create_db_refuses_existing_database_without_modifying_it(