| 1615 | |
| 1616 | _FrameInfo = namedtuple('_FrameInfo', ('frame',) + Traceback._fields) |
| 1617 | class FrameInfo(_FrameInfo): |
| 1618 | def __new__(cls, frame, filename, lineno, function, code_context, index, *, positions=None): |
| 1619 | instance = super().__new__(cls, frame, filename, lineno, function, code_context, index) |
| 1620 | instance.positions = positions |
| 1621 | return instance |
| 1622 | |
| 1623 | def __repr__(self): |
| 1624 | return ('FrameInfo(frame={!r}, filename={!r}, lineno={!r}, function={!r}, ' |
| 1625 | 'code_context={!r}, index={!r}, positions={!r})'.format( |
| 1626 | self.frame, self.filename, self.lineno, self.function, |
| 1627 | self.code_context, self.index, self.positions)) |
| 1628 | |
| 1629 | def getouterframes(frame, context=1): |
| 1630 | """Get a list of records for a frame and all higher (calling) frames. |
no outgoing calls
no test coverage detected