import types fails

Greg Fortune lists at
Wed Aug 28 01:45:21 CEST 2002

Richie Hindle wrote:

>> That's really cool :)  Unfortunately, the call into QThread's run method
>> (which is where everything is dying) is a C module call and the python
>> that gets executed by that library call does not get traced.
> I've never used Qt (though it's high on my list of things to look at
> when I win the lottery and give up my day job 8-) but it's a general
> Python rule that settrace() only works on the current thread.  So you'll
> need to somehow call blackbox.recordTo() from the thread you need to
> examine - ideally at the beginning of that thread's Python code.  Or
> call it in the module that's doing the "import types", before the
> import.

Never did get that to work 'cause the problem is actually with the import 
so I can't even import blackbox.  imp.load_module() did work inside the 
thread, but only on built-in modules.. go figure :)

I've got a couple more things to check in the meantime so when I figure out 
what it is, I'll post a reply here...


More information about the Python-list mailing list