diff --git a/backend/politrack/sources/parlament/news.py b/backend/politrack/sources/parlament/news.py index 93bfad3..2c878f3 100644 --- a/backend/politrack/sources/parlament/news.py +++ b/backend/politrack/sources/parlament/news.py @@ -48,7 +48,11 @@ class ParlamentPress(Adapter): def start(self, ctx: RunContext) -> Iterator[Request]: last = ctx.state.get("last_date") backfill = int(ctx.params.get("backfill_days", 365)) - since = (date.fromisoformat(last) - timedelta(days=2)) if last else date.today() - timedelta(days=backfill) + # an explicit backfill_days (history backfill) wins over the cursor of the regular runs + if last and "backfill_days" not in ctx.params: + since = date.fromisoformat(last) - timedelta(days=2) + else: + since = date.today() - timedelta(days=backfill) yield list_request(110, {"DATERANGE": [since.isoformat(), date.today().isoformat()]}, kind="list", meta={"since": since.isoformat()})