[IPython-user] Problems with IPython and gtk-win32-devel-2.6.10-rc1.exe/pygtk-2.6.3.1.win32-py2.4

Fernando Perez Fernando.Perez at colorado.edu
Mon Oct 31 08:53:31 CST 2005


Sean M. Moore wrote:
> I installed IPython yesterday to try it out, worked fine including the
> pylab mode
>  
> Today, I decided to update my python install as some of the 
> packages were getting a bit crufty, and now I am having some
> problems with IPython.
>  
> Actually IPython runs fine, but if I run -pylab, it runs really slowly -
> 
> like every character you type, you watch the cursor go back to the
> start of the line, and then move back to the end, and then accept
> the next charater, must be a couple of seconds for each character.
>  
> Needless to say this is excruciatingly painful.  

Mmh, this looks like a thread/timer related issue.  I can't test win32 right 
now, but can you play with the TIMEOUT parameter a little in the Shell.py 
file?  Try making it larger/smaller and see if that helps any.

Also, try changing the default bytecode switching interval for threads.  You 
can get the current value (normally 100) with

In [2]: sys.getcheckinterval
------> sys.getcheckinterval()
Out[2]: 100

and change it with:

In [3]: sys.setcheckinterval?
Type:           builtin_function_or_method
Base Class:     <type 'builtin_function_or_method'>
String Form:    <built-in function setcheckinterval>
Namespace:      Interactive
Docstring:
     setcheckinterval(n)

     Tell the Python interpreter to check for asynchronous events every
     n instructions.  This also affects how often thread switches occur.

By playing with these two parameters you may find a combination that makes 
life tolerable again.  I'd like to have a better answer for you, but I don't 
know enough about GTK threading to say anything of real value, I'm afraid. 
Let us know what playing with these two parameters gives you, and we'll take 
it from there.

Cheers,

f




More information about the IPython-user mailing list