Page MenuHomeSoftware Heritage

D214.diff
No OneTemporary

D214.diff

diff --git a/swh/scheduler/celery_backend/config.py b/swh/scheduler/celery_backend/config.py
--- a/swh/scheduler/celery_backend/config.py
+++ b/swh/scheduler/celery_backend/config.py
@@ -8,6 +8,7 @@
from celery import Celery
from celery.signals import setup_logging
+from celery.utils.log import ColorFormatter
from celery.worker.control import Panel
from kombu import Exchange, Queue
@@ -45,6 +46,13 @@
root_logger = logging.getLogger('')
root_logger.setLevel(logging.INFO)
+ if loglevel == logging.DEBUG:
+ color_formatter = ColorFormatter(format) if colorize else formatter
+ console = logging.StreamHandler()
+ console.setLevel(logging.DEBUG)
+ console.setFormatter(color_formatter)
+ root_logger.addHandler(console)
+
systemd_journal = JournalHandler()
systemd_journal.setLevel(logging.DEBUG)
systemd_journal.setFormatter(formatter)

File Metadata

Mime Type
text/plain
Expires
Wed, Dec 18, 1:19 AM (2 d, 4 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3214289

Event Timeline