| 1639 | |
| 1640 | _FrameInfo = namedtuple('_FrameInfo', ('frame',) + Traceback._fields) |
| 1641 | class FrameInfo(_FrameInfo): |
| 1642 | def __new__(cls, frame, filename, lineno, function, code_context, index, *, positions=None): |
| 1643 | instance = super().__new__(cls, frame, filename, lineno, function, code_context, index) |
| 1644 | instance.positions = positions |
| 1645 | return instance |
| 1646 | |
| 1647 | def __repr__(self): |
| 1648 | return ('FrameInfo(frame={!r}, filename={!r}, lineno={!r}, function={!r}, ' |
| 1649 | 'code_context={!r}, index={!r}, positions={!r})'.format( |
| 1650 | self.frame, self.filename, self.lineno, self.function, |
| 1651 | self.code_context, self.index, self.positions)) |
| 1652 | |
| 1653 | def getouterframes(frame, context=1): |
| 1654 | """Get a list of records for a frame and all higher (calling) frames. |
no outgoing calls
no test coverage detected
searching dependent graphs…