Skip to content

Commit 9cc4bc6

Browse files
committed
Remove attribute enumeration for FrameSummary, as it's linked to a definition with all attributes.
1 parent 93fb52b commit 9cc4bc6

2 files changed

Lines changed: 4 additions & 9 deletions

File tree

Doc/library/traceback.rst

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -147,11 +147,7 @@ Module-Level Functions
147147
:ref:`traceback object <traceback-objects>` *tb*. It is useful
148148
for alternate formatting of stack traces. The optional *limit* argument has
149149
the same meaning as for :func:`print_tb`. A "pre-processed" stack trace
150-
entry is a :class:`FrameSummary` object containing attributes
151-
:attr:`~FrameSummary.filename`, :attr:`~FrameSummary.lineno`,
152-
:attr:`~FrameSummary.name`, :attr:`~FrameSummary.line`,
153-
:attr:`~FrameSummary.end_lineno`, :attr:`~FrameSummary.colno`, and
154-
:attr:`~FrameSummary.end_colno` representing the
150+
entry is a :class:`FrameSummary` object with attributes representing the
155151
information that is usually printed for a stack trace.
156152

157153

Lib/traceback.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -115,11 +115,10 @@ def extract_tb(tb, limit=None):
115115
This is useful for alternate formatting of stack traces. If
116116
'limit' is omitted or None, all entries are extracted. A
117117
pre-processed stack trace entry is a FrameSummary object
118-
containing attributes filename, lineno, name, line, end_lineno,
119-
colno, and end_colno representing the information that is
120-
usually printed for a stack trace. The line is a string with
118+
representing the information that is usually printed for a
119+
stack trace. The line attribute is a string with
121120
leading and trailing whitespace stripped; if the source is not
122-
available it is None.
121+
available the corresponding attribute is None.
123122
"""
124123
return StackSummary._extract_from_extended_frame_gen(
125124
_walk_tb_with_full_positions(tb), limit=limit)

0 commit comments

Comments
 (0)