class traceback.StackSummary
-
classmethod extract(frame_gen, *, limit=None, lookup_lines=True, capture_locals=False) -
Construct a
StackSummaryobject from a frame generator (such as is returned bywalk_stack()orwalk_tb()).If limit is supplied, only this many frames are taken from frame_gen. If lookup_lines is
False, the returnedFrameSummaryobjects will not have read their lines in yet, making the cost of creating theStackSummarycheaper (which may be valuable if it may not actually get formatted). If capture_locals isTruethe local variables in eachFrameSummaryare captured as object representations.
-
classmethod from_list(a_list) -
Construct a
StackSummaryobject from a supplied old-style list of tuples. Each tuple should be a 4-tuple with filename, lineno, name, line as the elements.
Please login to continue.