from space_tracer import traced
def foo():
for _ in range(50000):
pass
@traced
def bar():
print('Done.')
foo()
bar()
What happened
IndexError, when I run the script regularly, not in live coding mode or under space_tracer.
Traceback (most recent call last):
File "/home/don/workspace/scratch/scratch2.py", line 8, in <module>
def bar():
File "/home/don/git/live-py-plugin/.tox/py310/lib/python3.10/site-packages/space_tracer/main.py", line 263, in traced
if is_in_traced_module():
File "/home/don/git/live-py-plugin/.tox/py310/lib/python3.10/site-packages/space_tracer/main.py", line 260, in is_in_traced_module
expected_frame = call_stack[3]
IndexError: list index out of range
What I wanted to happen
Just print Done..
My environment
Describe the versions of everything you were using:
What I did
Isolate the code to be traced.
What happened
IndexError, when I run the script regularly, not in live coding mode or under space_tracer.
What I wanted to happen
Just print
Done.
.My environment
Describe the versions of everything you were using: