From 6ed053c4259705e055a70ed18c2336123250b887 Mon Sep 17 00:00:00 2001 From: Daniel Schadt Date: Sun, 23 Apr 2023 11:37:28 +0200 Subject: fietscron: don't run both queues This has always been intended, but we forgot to set the had_hq_item flag. --- fietsboek/scripts/fietscron.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fietsboek/scripts/fietscron.py b/fietsboek/scripts/fietscron.py index d8476a9..b968a18 100644 --- a/fietsboek/scripts/fietscron.py +++ b/fietsboek/scripts/fietscron.py @@ -102,10 +102,11 @@ def run_hittekaart(engine: Engine, data_manager: DataManager, redis: Redis, conf item = redis.spop("hittekaart:queue:high") if item is None: break + had_hq_item = True user = session.execute(select(models.User).filter_by(id=int(item))).scalar() if user is None: LOGGER.debug("User %d had a high-priority queue entry but was not found", item) - break + continue for mode in modes: LOGGER.info("Generating %s for user %d (high-priority)", mode.value, user.id) -- cgit v1.2.3