diff --git a/solvable/src/event_handler_main.py b/solvable/src/event_handler_main.py index bdcc746..54f1971 100644 --- a/solvable/src/event_handler_main.py +++ b/solvable/src/event_handler_main.py @@ -3,7 +3,7 @@ from ast import literal_eval from tornado.ioloop import IOLoop from tfw.components import IdeEventHandler, TerminalEventHandler, ProcessManagingEventHandler, BashMonitor -from tfw.components import TerminalCommands, LogMonitor +from tfw.components import TerminalCommands, LogMonitoringEventHandler from tfw.networking import MessageSender, TFWServerConnector from tfw.config import TFWENV from tfw.config.logs import logging @@ -83,14 +83,17 @@ if __name__ == '__main__': dirmonitor=ide.monitor, log_tail=2000 ) - LogMonitor('webservice', log_tail=2000).watch() # Sends live logs of webservice process to frontend + logmonitor = LogMonitoringEventHandler( # Sends live logs of webservice process to frontend + 'webservice', + log_tail=2000 + ) + eventhandlers = {ide, terminal, processmanager, logmonitor} terminal.historymonitor.subscribe_callback(cenator) commands = TestCommands(bashrc=f'/home/{TAOENV.USER}/.bashrc') terminal.historymonitor.subscribe_callback(commands.callback) - eventhandlers = {ide, terminal, processmanager} try: IOLoop.instance().start() finally: