1
0
mirror of https://github.com/dkmstr/openuds.git synced 2024-12-23 17:34:17 +03:00

Fixed logger on Windows (import mistake)

This commit is contained in:
Adolfo Gómez 2022-06-17 21:59:24 +02:00
parent 3a4d571a6c
commit 18c5e3a242
4 changed files with 4 additions and 7 deletions

View File

@ -67,7 +67,7 @@ if __name__ == "__main__":
# Note: Signals are only checked on python code execution, so we create a timer to force call back to python
timer = QTimer(qApp)
timer.start(1000)
timer.timeout.connect(lambda *a: None) # timeout can be connected to a callable
timer.timeout.connect(lambda *a: None) # type: ignore # timeout can be connected to a callable
qApp.exec()

View File

@ -31,7 +31,6 @@
from . import types
from . import rest
from . import platform
from . import tools
__title__ = 'udsactor'
__author__ = 'Adolfo Gómez <dkmaster@dkmon.com>'

View File

@ -28,23 +28,23 @@
'''
@author: Adolfo Gómez, dkmaster at dkmon dot com
'''
from re import I
import threading
import ipaddress
import typing
from udsactor.log import logger
if typing.TYPE_CHECKING:
from udsactor.types import InterfaceInfoType
class ScriptExecutorThread(threading.Thread):
def __init__(self, script: str) -> None:
super(ScriptExecutorThread, self).__init__()
self.script = script
def run(self) -> None:
from udsactor.log import logger
try:
logger.debug('Executing script: {}'.format(self.script))
exec(self.script, globals(), None) # pylint: disable=exec-used
@ -69,7 +69,6 @@ def validNetworkCards(
try:
subnet = strToNoIPV4Network(net)
except Exception as e:
logger.error('Invalid network: {}'.format(e))
subnet = None
if subnet is None:

View File

@ -35,7 +35,6 @@ import tempfile
import typing
import servicemanager
from udsactor import service # pylint: disable=import-error
# Valid logging levels, from UDS Broker (uds.core.utils.log).
from .. import loglevel