From 5ff834b794390f23dea8f6913ed989ff06481293 Mon Sep 17 00:00:00 2001 From: Stan <1939656+GDay@users.noreply.github.com> Date: Sat, 1 Aug 2026 00:55:17 +0200 Subject: [PATCH] More str --- django_q/monitor_terminal.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/django_q/monitor_terminal.py b/django_q/monitor_terminal.py index 94877dd..4c6ab20 100644 --- a/django_q/monitor_terminal.py +++ b/django_q/monitor_terminal.py @@ -97,6 +97,8 @@ def monitor(run_once=False, broker=None): for stat in stats: status = stat.status # color status + if stat.status == Conf.STARTING: + status = term.yellow(str(Conf.STARTING)) if stat.status == Conf.WORKING: status = term.green(str(Conf.WORKING)) elif stat.status == Conf.STOPPING: @@ -105,6 +107,8 @@ def monitor(run_once=False, broker=None): status = term.red(str(Conf.STOPPED)) elif stat.status == Conf.IDLE: status = str(Conf.IDLE) + else: + status = _("Unknown") # color q's tasks = str(stat.task_q_size) if stat.task_q_size > 0: @@ -138,7 +142,7 @@ def monitor(run_once=False, broker=None): ) print( term.move(i, 3 * col_width) - + term.center(workers, width=col_width - 1) + + term.center(str(workers), width=col_width - 1) ) print( term.move(i, 4 * col_width)