From c206366e000647848800120bc197dbd01ca4038d Mon Sep 17 00:00:00 2001 From: Joshua Welsh Date: Thu, 6 May 2021 12:17:52 +0100 Subject: [PATCH] Use the correct rq connection in `get_queues_status` This fixes rq throwing a NoRedisConnectionException exception when configured with a non-local redis instance. --- redash/monitor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/redash/monitor.py b/redash/monitor.py index b6f7054783..41f3dca122 100644 --- a/redash/monitor.py +++ b/redash/monitor.py @@ -30,7 +30,7 @@ def get_object_counts(): def get_queues_status(): - return {queue.name: {"size": len(queue)} for queue in Queue.all()} + return {queue.name: {"size": len(queue)} for queue in Queue.all(connection=rq_redis_connection)} def get_db_sizes():