Freeze with wxpython on python 2.3 or python 2.4 on Win32 with Thread

T

Tsubasa[Hokage]

first problem:

With Idle environnement under Win32, all freeze after with bunch of
code:

#!/usr/bin/python
import threading,time

class T (threading.Thread) :
def __init__(self,_a,_b) :
threading.Thread.__init__(self)
self.a = _a
self.b = _b
def run(self) :
print "T(%d,%d)"%(self.a,self.b)
time.sleep(3)
print "T(%d,%d)=>%d"%(self.a,self.b,self.a+self.b)
return self.a+self.b

t = T(3,5)
t.start()


All freeze when sleep command are execute.
Second part of this problem, I have a GUI in wxpython, when I create
new thread i can't write new data in widget like a multibox when i am
in a thread :( but i can retrieve data ( GetValue works but SetValue
freeze ).

Thanks
 

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
473,961
Messages
2,570,130
Members
46,689
Latest member
liammiller

Latest Threads

Top