Module zut.config

Configuration (logging, settings, etc).

For usage of logging see zut.get_logger and (less frequently zut.log_warnings).

Functions

configure_logging([level, file_level, ...])

find_to_root(name[, start_dir])

Find the given file name from the given start directory (or current working directory if none given), up to the root.

get_lang()

Return current locale lang, for example: fr_FR.

get_logging_config([level, file_level, ...])

load_dotenv([path, encoding, override, parents])

Load .env from the given or current directory (or the given file if any) to environment variables.

parse_properties(content)

Parse properties/ini/env file content.

register_locale([name])

Register a locale for the entire application (system default locale if argument value is None).

use_locale([name])

Use a locale temporary (in the following thread-local block/context).

Classes

ColoredFormatter([fmt, datefmt, style, ...])

ColoredRecord(record)

LogCounter(*[, level, exit_handler])

A logging handler that counts warnings and errors.