Text frames for tracebacks.
typing
terminal
syntax_divisor
syntax_divisor = (None, 48*"┄")
frame_divisor
frame_divisor = (None, "")
dataclass
Frame
Traceback frame class to be instantiated for rendered.
Frameresourcestr
resource:(str) = None
Framefactorstr
factor:(str) = None
Frameelementstr
element:(str) = None
Frameareatyping.Tuple[int, int]
area:(typing.Tuple[int, int]) = ()
Framesourcestr
source:(str) = None
frame
frame(index, record)
Construct sequence for a single frame record.
path
path(stack)
Construct frame for an entire stack.
seq
seq = [
{
'function': 'control',
'factor': "fault.system.process",
'resource': "/python/lib/fault/system/process.py",
'area': 731,
'source': " Fork.trap(main, *args, **kw)",
}, {
'function': 'trap',
'factor': "fault.system.process",
'resource': "/python/lib/fault/system/process.py",
'area': 635,
'source': "return controller(*args, **kw) # Process replacement point.",
}, {
'function': 'main',
'factor': "fault.system.bin.subexec",
'resource': "/python/lib/fault/system/bin/subexec.py",
'area': 123,
'source': "module_path = inv.args[count] # No module specified?"
}
]
k
k = {
'exception': "IndexError",
'message': "list index out of range"
}
pframe
pframe(data)