From 4d2a52ddb181c5ad9f09e475d80474067f17fac5 Mon Sep 17 00:00:00 2001 From: Ruben van de Ven Date: Tue, 12 Nov 2019 17:57:09 +0100 Subject: [PATCH] Tornado listens in own thread and Fr2 background color in timeline --- hugvey/panopticon.py | 7 +++++-- www/timeline.html | 3 +++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/hugvey/panopticon.py b/hugvey/panopticon.py index 10f6665..f22b280 100644 --- a/hugvey/panopticon.py +++ b/hugvey/panopticon.py @@ -303,20 +303,23 @@ class Panopticon(object): {"path": web_dir, "default_filename": 'index.html'}), ], debug=True) - self.application.listen(config['web']['port']) # self.loop.configure(evt_loop) def start(self): + + evt_loop = asyncio.new_event_loop() asyncio.set_event_loop(evt_loop) self.loop = tornado.ioloop.IOLoop.current() + + self.application.listen(self.config['web']['port']) + thread = threading.Thread( target=self.broadcastLoggingQueueToWs, kwargs={'wsHandler': self.wsHandler, 'q': self.command.logQueue}, name=f"panopticon/logws") thread.start() - task = evt_loop.create_task( self.statusSender(self.wsHandler)) diff --git a/www/timeline.html b/www/timeline.html index 3dd0edc..92f7196 100644 --- a/www/timeline.html +++ b/www/timeline.html @@ -109,6 +109,9 @@ font-size: 20pt; } .status-running.lang-fr-FR{ + background: #f00; +} +.status-running.lang-fr-FR2{ background: #5a434d; } .status-running.lang-de-DE{