|
From: Stefan Sonnenberg-C. <ste...@py...> - 2009-05-18 10:50:00
|
Am Mo, 18.05.2009, 12:30, schrieb Benjamin Donnachie: > I am using the binary Linux pyfltk v1.1.4 build from the sourceforge > website together with v2.5.2 of Python and v1.1.9 of fltk to create a > GUI wrapper around a command line process to use hdparm to securely > erase harddrives. > > To provide user feedback I am using Fl_repeat_timeout and then > Fl.add_timeout to update a status bar and provide an animated image. > Separate threads are called by the main program to process each drive > using thread.start_new_thread(). The threads then invoke the command > line utilities using commands.getstatusoutput(). The utilities do not > immediately return - especially when falling back to the wipe function > - and this causes the script to hang and the progress bar / animation > to freeze giving the user the impression that it has hung. I have > tried replacing commands.getstatusoutput() with subprocess.call() but > the problem persists. > > This is my first time using Python and fltk. I've tried searching for > more information on python threads but pretty much drawn a blank. > Consequently, I should be grateful for any advice on how to ensure > that the timer function continues to operate. > > Ben > > ------------------------------------------------------------------------------ > Crystal Reports - New Free Runtime and 30 Day Trial > Check out the new simplified licensing option that enables > unlimited royalty-free distribution of the report engine > for externally facing server and web deployment. > http://p.sf.net/sfu/businessobjects > _______________________________________________ > Pyfltk-user mailing list > Pyf...@li... > https://lists.sourceforge.net/lists/listinfo/pyfltk-user > > My guess is, that this has nothing to do with pyFLTK. (Having used heavy threading besides pyFLTK in the same program) But please post your code, so that someone has a chance to spot the critical part of your code. |