log_config
log_config
¶
Global logging configuration for the Diapason CLI.
Classes¶
SanitizingFormatter
¶
Bases: Formatter
Formatter that redacts credentials from log messages.
Functions:¶
setup_logging
¶
setup_logging(
verbose: bool = False,
quiet: bool = False,
log_file: Optional[Union[str, Path]] = None,
) -> Logger
Configure the diapason logger.
| PARAMETER | DESCRIPTION |
|---|---|
verbose
|
Set log level to DEBUG.
TYPE:
|
quiet
|
Set log level to ERROR (overrides verbose if both set).
TYPE:
|
log_file
|
Path for a rotating file handler. When verbose is
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
The configured ``diapason`` logger.
|
|