| 1705 | |
| 1706 | _FrameInfo = namedtuple('_FrameInfo', ('frame',) + Traceback._fields) |
| 1707 | class FrameInfo(_FrameInfo): |
| 1708 | def __new__(cls, frame, filename, lineno, function, code_context, index, *, positions=None): |
| 1709 | instance = super().__new__(cls, frame, filename, lineno, function, code_context, index) |
| 1710 | instance.positions = positions |
| 1711 | return instance |
| 1712 | |
| 1713 | def __repr__(self): |
| 1714 | return ('FrameInfo(frame={!r}, filename={!r}, lineno={!r}, function={!r}, ' |
| 1715 | 'code_context={!r}, index={!r}, positions={!r})'.format( |
| 1716 | self.frame, self.filename, self.lineno, self.function, |
| 1717 | self.code_context, self.index, self.positions)) |
| 1718 | |
| 1719 | def getouterframes(frame, context=1): |
| 1720 | """Get a list of records for a frame and all higher (calling) frames. |
no outgoing calls
no test coverage detected