In my app I'm trying to write to a file in a seperate thread, but somehow I can't get threading to work correctly. Basically what I'm doing is:

import thread

thread.start_new_thread(self.write, ())

def write(self):
for i in range(2):"Running: ", i)

When I use this method the UI freezes. I read the piece about active objects in the manual, but that doesn't seem to be what I want. Any suggestions or simple example how to get threads working?