taskbridgeapp.gui.viewmodel.threadedtasks.LoggingThread

class taskbridgeapp.gui.viewmodel.threadedtasks.LoggingThread(logging_level, log_stdout=False, log_file=True, log_gui=True)

Bases: QThread

Used to collect logs.

Methods

run

Keeps the logging thread running until it is stopped.

set_logging_level

Changes the logging level.

setup_logging

Sets up the logging system as configured in the constructor.

Attributes

__display_name__

__name__

__orig_bases__

__sphinx_decorator_args__

__sphinx_mock__

stop_logging

When set, causes this thread to stop.

__call__(*args, **kwargs)

Call self as a function.

Return type:

Any

__init__(logging_level, log_stdout=False, log_file=True, log_gui=True)

Initialises the logging thread.

Parameters:
  • logging_level (str) – the logging level which can be DEBUG, INFO, WARNING or CRITICAL.

  • log_stdout (bool) – if True, logs are sent to standard out.

  • log_file (bool) – if True, logs are sent to file.

  • log_gui (bool) – if True, logs are sent to a function which handles displaying logs in the GUI.

log_signal

Log messages are emitted to this signal.

alias of str

run()

Keeps the logging thread running until it is stopped.

Return type:

None

set_logging_level(logging_level)

Changes the logging level.

Parameters:

logging_level (str) – the desired logging level.

Return type:

None

setup_logging()

Sets up the logging system as configured in the constructor.

Return type:

None

stop_logging = <threading.Event at 0x7e57e92e1820: unset>

When set, causes this thread to stop.