From ef481498440d8dbcb064b7f7463640017769a76b Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Thu, 26 Jan 2023 07:52:37 -0800 Subject: [PATCH] Show import queue in Celery admin --- bookwyrm/templates/settings/celery.html | 12 +++++++++--- bookwyrm/views/admin/celery_status.py | 1 + 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/bookwyrm/templates/settings/celery.html b/bookwyrm/templates/settings/celery.html index b2bd95601..7ce6553fb 100644 --- a/bookwyrm/templates/settings/celery.html +++ b/bookwyrm/templates/settings/celery.html @@ -13,24 +13,30 @@

{% trans "Queues" %}

-
+

{% trans "Low priority" %}

{{ queues.low_priority|intcomma }}

-
+

{% trans "Medium priority" %}

{{ queues.medium_priority|intcomma }}

-
+

{% trans "High priority" %}

{{ queues.high_priority|intcomma }}

+
+
+

{% trans "Imports" %}

+

{{ queues.imports|intcomma }}

+
+
{% else %} diff --git a/bookwyrm/views/admin/celery_status.py b/bookwyrm/views/admin/celery_status.py index 5221fd619..0e88f55f1 100644 --- a/bookwyrm/views/admin/celery_status.py +++ b/bookwyrm/views/admin/celery_status.py @@ -36,6 +36,7 @@ class CeleryStatus(View): "low_priority": r.llen("low_priority"), "medium_priority": r.llen("medium_priority"), "high_priority": r.llen("high_priority"), + "imports": r.llen("imports"), } # pylint: disable=broad-except except Exception as err: