From d68f2a604a9fe8a840a6cb39f83c7c977002a3a5 Mon Sep 17 00:00:00 2001 From: TLSM Date: Mon, 27 Jun 2022 02:15:35 -0400 Subject: [PATCH] Check bot award timers more frequently. Also: change to docker-compose.yml is to see if it'll fix the Github tests failing. Lumped in here because it's too dumb to make a commit for by itself. --- docker-compose.yml | 2 +- files/helpers/cron.py | 9 +++------ 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index b53fb74b3..52d79dbfd 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -27,7 +27,7 @@ services: postgres: image: postgres:12.3 - command: ["postgres", "-c", "log_statement=all"] + #command: ["postgres", "-c", "log_statement=all"] # uncomment this if u wanna output all SQL queries to the console volumes: - "./schema.sql:/docker-entrypoint-initdb.d/00-schema.sql" diff --git a/files/helpers/cron.py b/files/helpers/cron.py index 47a4595a1..b3bc8ccbe 100644 --- a/files/helpers/cron.py +++ b/files/helpers/cron.py @@ -21,20 +21,17 @@ def cron(every_5m, every_1h, every_1d, every_1mo): if every_5m: lottery.check_if_end_lottery_task() offsitementions.offsite_mentions_task() - g.db.commit() if every_1h: - pass + awards.award_timers_bots_task() if every_1d: stats.generate_charts_task(const.SITE) route_static.stats_cached() - awards.award_timers_bots_task() sub_inactive_purge_task() - g.db.commit() if every_1mo: give_monthly_marseybux_task() - g.db.commit() - g.db.close() \ No newline at end of file + g.db.commit() + g.db.close()