Task 13: wire geo_batch_lookup through dependency injection and mark task completed

This commit is contained in:
2026-04-14 09:51:23 +02:00
parent 88715ab07f
commit 56ade7fb08
6 changed files with 52 additions and 37 deletions

View File

@@ -31,6 +31,7 @@ from app.dependencies import (
AppDep,
AuthDep,
Fail2BanSocketDep,
GeoBatchLookupDep,
HttpSessionDep,
SchedulerDep,
get_db,
@@ -122,6 +123,7 @@ async def run_import_now(
db: DbDep,
_auth: AuthDep,
socket_path: Fail2BanSocketDep,
geo_batch_lookup: GeoBatchLookupDep,
) -> ImportRunResult:
"""Download and apply all enabled blocklist sources immediately.
@@ -140,7 +142,7 @@ async def run_import_now(
http_session,
socket_path,
geo_is_cached=geo_service.is_cached,
geo_batch_lookup=geo_service.lookup_batch,
geo_batch_lookup=geo_batch_lookup,
ban_ip=jail_service.ban_ip,
)