cars.core.cars_logging
cCars logging module: contains cars logging setup logger for main thread and workers
Module Contents
Functions
|
Setup the CARS logging configuration |
|
Add enforced message with INFO level |
|
Add dated file handler to the logger. |
|
Wrapper logger function to wrap worker func |
|
Logger function to wrap worker func (with non local method) |
|
Setup the worker logger inside wrapper |
Attributes
- cars.core.cars_logging.PROGRESS = 21
- cars.core.cars_logging.create(loglevel='PROGRESS')[source]
Setup the CARS logging configuration
- Parameters
loglevel – log level default WARNING
- cars.core.cars_logging.add_progress_message(message)[source]
Add enforced message with INFO level to stdout and logging file
- Parameters
message – logging message
- cars.core.cars_logging.add_log_file(out_dir, command)[source]
Add dated file handler to the logger.
- Parameters
out_dir (str) – output directory in which the log file will be created
command (str) – command name which will be part of the log file name
- cars.core.cars_logging.wrap_logger(func, log_dir, log_level)[source]
Wrapper logger function to wrap worker func and setup the worker logger :param func: wrapped function :param log_dir: output directory of worker logs :param log_level: logging level of the worker logs