debug_toolbar/utils.py
def tidy_stacktrace(stack):
    """
    Clean up stacktrace and remove all entries that are excluded by the
    HIDE_IN_STACKTRACES setting.

    ``stack`` should be a list of frame tuples from ``inspect.stack()`` or
    ``debug_toolbar.utils.get_stack()``.
    """
    _stack_trace_deprecation_warning()

    trace = []
    excluded_modules = dt_settings.get_config()["HIDE_IN_STACKTRACES"]
    for frame, path, line_no, func_name, text in (f[:5] for f in stack):
        if _is_excluded_frame(frame, excluded_modules):
            continue
        text = "".join(text).strip() if text else ""
        frame_locals = (
            frame.f_locals
            if dt_settings.get_config()["ENABLE_STACKTRACES_LOCALS"]
            else None
        )
        trace.append((path, line_no, func_name, text, frame_locals))
    return trace

    Clean up stacktrace and remove all entries that are excluded by the
    HIDE_IN_STACKTRACES setting.

    ``stack`` should be a list of frame tuples from ``inspect.stack()`` or
    ``debug_toolbar.utils.get_stack()``.
    
Clean up stacktrace and remove all entries that are excluded by the
HIDE_IN_STACKTRACES setting.


Clean up stacktrace and remove all entries that are excluded by the HIDE_IN_STACKTRACES setting .
def tidy_stacktrace(stack):
    _stack_trace_deprecation_warning()
    trace = []
    excluded_modules = dt_settings.get_config()["HIDE_IN_STACKTRACES"]
    for frame, path, line_no, func_name, text in (f[:5] for f in stack):
        if _is_excluded_frame(frame, excluded_modules):
            continue
        text = "".join(text).strip() if text else ""
        frame_locals = (
            frame.f_locals
            if dt_settings.get_config()["ENABLE_STACKTRACES_LOCALS"]
            else None
        )
        trace.append((path, line_no, func_name, text, frame_locals))
    return trace
def tidy_stacktrace ( stack ) : _stack_trace_deprecation_warning ( ) trace = [ ] excluded_modules = dt_settings . get_config ( ) [ "HIDE_IN_STACKTRACES" ] for frame , path , line_no , func_name , text in ( f [ : 5 ] for f in stack ) : if _is_excluded_frame ( frame , excluded_modules ) : continue text = "" . join ( text ) . strip ( ) if text else "" frame_locals = ( frame . f_locals if dt_settings . get_config ( ) [ "ENABLE_STACKTRACES_LOCALS" ] else None ) trace . append ( ( path , line_no , func_name , text , frame_locals ) ) return trace
Clean up stacktrace and remove all entries that are excluded by the
HIDE_IN_STACKTRACES setting.
Clean up stacktrace and remove all entries that are excluded by the HIDE_IN_STACKTRACES setting .
"""
    Clean up stacktrace and remove all entries that are excluded by the
    HIDE_IN_STACKTRACES setting.

    ``stack`` should be a list of frame tuples from ``inspect.stack()`` or
    ``debug_toolbar.utils.get_stack()``.
    """
stack