class_docstr: A Console renderable that renders a traceback.
  
  Args:
      trace (Trace, optional): A `Trace` object produced from `extract`. Defaults to None, which uses
          the last exception.
      width (Optional[int], optional): Number of characters used to traceback. Defaults to 100.
      extra_lines (int, optional): Additional lines of code to render. Defaults to 3.
      theme (str, optional): Override pygments theme used in traceback.
      word_wrap (bool, optional): Enable word wrapping of long lines. Defaults to False.
      show_locals (bool, optional): Enable display of local variables. Defaults to False.
      indent_guides (bool, optional): Enable indent guides in code and locals. Defaults to True.
      locals_max_length (int, optional): Maximum length of containers before abbreviating, or None for no abbreviation.
          Defaults to 10.
      locals_max_string (int, optional): Maximum length of string before truncating, or None to disable. Defaults to 80.
      locals_hide_dunder (bool, optional): Hide locals prefixed with double underscore. Defaults to True.
      locals_hide_sunder (bool, optional): Hide locals prefixed with single underscore. Defaults to False.
      suppress (Sequence[Union[str, ModuleType]]): Optional sequence of modules or paths to exclude from traceback.
      max_frames (int): Maximum number of frames to show in a traceback, 0 for no maximum. Defaults to 100.
code: def __init__(
      self,
      trace: Optional[Trace] = None,
      *,
      width: Optional[int] = 100,
      extra_lines: int = 3,
      theme: Optional[str] = None,
      word_wrap: bool = False,
      show_locals: bool = False,
      locals_max_length: int = LOCALS_MAX_LENGTH,
      locals_max_string: int = LOCALS_MAX_STRING,
      locals_hide_dunder: bool = True,
      locals_hide_sunder: bool = False,
      indent_guides: bool = True,
      suppress: Iterable[Union[str, ModuleType]] = (),
      max_frames: int = 100,
  ):
      if trace is None:
          exc_type, exc_value, traceback = sys.exc_info()
          if exc_type is None or exc_value is None or traceback is None:
              raise ValueError(
                  "Value for 'trace' required if not called in except: block"
              )
          trace = self.extract(
              exc_type, exc_value, traceback, show_locals=show_locals
          )
      self.trace = trace
      self.width = width
      self.extra_lines = extra_lines
      self.theme = Syntax.get_theme(theme or "ansi_dark")
      self.word_wrap = word_wrap
      self.show_locals = show_locals
      self.indent_guides = indent_guides
      self.locals_max_length = locals_max_length
      self.locals_max_string = locals_max_string
      self.locals_hide_dunder = locals_hide_dunder
      self.locals_hide_sunder = locals_hide_sunder
  
      self.suppress: Sequence[str] = []
      for suppress_entity in suppress:
          if not isinstance(suppress_entity, str):
              assert (
                  suppress_entity.__file__ is not None
              ), f"{suppress_entity!r} must be a module with '__file__' attribute"
              path = os.path.dirname(suppress_entity.__file__)
          else:
              path = suppress_entity
          path = os.path.normpath(os.path.abspath(path))
          self.suppress.append(path)
      self.max_frames = max(4, max_frames) if max_frames > 0 else 0
  
imports: from __future__ import absolute_import
  import linecache
  import os
  import platform
  import sys
  from dataclasses import dataclass, field
  from traceback import walk_tb
  from types import ModuleType, TracebackType
  from typing import Any, Callable, Dict, Iterable, List, Optional, Sequence, Tuple, Type, Union
  from pygments.lexers import guess_lexer_for_filename
  from pygments.token import Comment, Keyword, Name, Number, Operator, String
  from pygments.token import Text
  from pygments.token import Token
  from pygments.util import ClassNotFound
  from .None import pretty
  from ._loop import loop_last
  from .columns import Columns
  from .console import Console, ConsoleOptions, ConsoleRenderable, RenderResult, group
  from .constrain import Constrain
  from .highlighter import RegexHighlighter, ReprHighlighter
  from .panel import Panel
  from .scope import render_scope
  from .style import Style
  from .syntax import Syntax
  from .text import Text
  from .theme import Theme
label_desc: Use image node_id 1 to create a new Traceback object  with example: obj = Traceback(trace)