Skip to content

logging_config

LoggingConfig

Source code in griptape/configs/logging/logging_config.py
@define
class LoggingConfig:
    logger_name: str = field(default="griptape", kw_only=True)

    def __attrs_post_init__(self) -> None:
        logger = logging.getLogger(self.logger_name)
        logger.setLevel(logging.INFO)
        logger.propagate = False
        logger.addHandler(RichHandler(show_time=True, show_path=False))

logger_name: str = field(default='griptape', kw_only=True) class-attribute instance-attribute

__attrs_post_init__()

Source code in griptape/configs/logging/logging_config.py
def __attrs_post_init__(self) -> None:
    logger = logging.getLogger(self.logger_name)
    logger.setLevel(logging.INFO)
    logger.propagate = False
    logger.addHandler(RichHandler(show_time=True, show_path=False))