<#9347 feat: Limit the traceback in console logs f...
# meltano-repo-activity
g
#9347 feat: Limit the traceback in console logs format to two frames Pull request opened by edgarrmondragon ## Description Tracebacks are very hard to read at the moment, mostly because they are extremely long in most cases. This should ensure that the only most important context is displayed. The full traceback can be recovered by enabling debug level logs, or by using a custom logging configuration file. ## Related Issues NA ## Summary by Sourcery Introduce a configurable
max_frames
parameter to cap traceback depth in console logs and default it to two frames for non-debug levels, while preserving full tracebacks in debug mode. New Features: • Add
max_frames
argument to
rich_exception_formatter_factory
and
console_log_formatter
to control the number of displayed traceback frames. • Automatically set
max_frames
to 2 for normal log levels and to unlimited in debug within the default logging configuration. Enhancements: • Normalize and unify log level casing and level handling in
default_config
and
setup_logging
. Documentation: • Update logging guide to document the new
max_frames
option and its default value for console formatting. Tests: • Introduce
deep_exc_info
fixture and corresponding test to assert both limited and unlimited frame display behaviors. meltano/meltano