tracing crash

N

Nir Aides

Hi,

I am facing a strange problem.
I will appreciate an explanation and a work around for the problem.

Look in the following code paste. It seems that taking a reference to
the frame object crashes python in some scripts:

#
# trace_hell.py
#
# crashes with spe (stani's python editor) v0.7.3.a
#
# to see the crash add "import trace_hell; trace_hell.unleash_hell()" as
# the first line in spe.py
#
# 1. The statement that triggers the crash is "g_frame = frame"
#

import sys

g_frame = None

def tracer(frame, event, arg):
global g_frame
g_frame = frame
return None

def unleash_hell():
sys.settrace(tracer)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,240
Messages
2,571,211
Members
47,845
Latest member
vojosay

Latest Threads

Top