fastiot.core.logger module

fastiot.core.logger.setup_logger(name='root')[source]

This logging is a wrapper for logging from python, you can use it like following. Also the FASTIOT_LOG_LEVEL must be set to the expected level. s. https://docs.python.org/3/library/logging.html#logging-levels

from fastiot import logging

logging.debug('debug message')
logging.info('info message')
fastiot.core.logger.get_log_config(level=20)[source]

This function is used to set the logging configuration globally, now the console log should have this format: timestamp: LOG_LEVEL module name: Log message If the log should be saved to a file, this configuration can also be modified by using logging.Filehandler.

Return type:

Dict