MCPcopy Index your code
hub / github.com/python/cpython / distb

Function distb

Lib/dis.py:140–151  ·  view source on GitHub ↗

Disassemble a traceback (default: last traceback).

(tb=None, *, file=None, show_caches=False, adaptive=False, show_offsets=False, show_positions=False)

Source from the content-addressed store, hash-verified

138 type(x).__name__)
139
140def distb(tb=None, *, file=None, show_caches=False, adaptive=False, show_offsets=False, show_positions=False):
141 """Disassemble a traceback (default: last traceback)."""
142 if tb is None:
143 try:
144 if hasattr(sys, 'last_exc'):
145 tb = sys.last_exc.__traceback__
146 else:
147 tb = sys.last_traceback
148 except AttributeError:
149 raise RuntimeError("no last traceback to disassemble") from None
150 while tb.tb_next: tb = tb.tb_next
151 disassemble(tb.tb_frame.f_code, tb.tb_lasti, file=file, show_caches=show_caches, adaptive=adaptive, show_offsets=show_offsets, show_positions=show_positions)
152
153# The inspect module interrogates this dictionary to build its
154# list of CO_* constants. It is also used by pretty_flags to

Callers 1

disFunction · 0.85

Calls 1

disassembleFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…