This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: GUI for Python 2.3, 2.4, and 2.5 is very sluggish
Type: Stage:
Components: IDLE Versions: Python 2.5
process
Status: closed Resolution: works for me
Dependencies: Superseder:
Assigned To: kbk Nosy List: g4rlik, kbk
Priority: normal Keywords:

Created on 2006-12-06 23:44 by g4rlik, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (9)
msg30746 - (view) Author: g4rlik (g4rlik) Date: 2006-12-06 23:44
The GUI for Python versions 2.3, 2.4, and 2.5 are very sluggish.  When I type in them, or simply move them around my desktop, they are very slow. 

Someone helping me from help@python.org was able to guess that the reason the GUI is slow for me is because of the subprocesses running, and he was right.

To cope with this problem, I created an idle.txt file, and added this to the first line of it:

c:\python25\python c:\python25\Lib\idlelib\idle.py -n

After that I saved the extension to .bat and now when I run that file, the Python GUI opens without any subprocesses running and I have no problem.  However, I'd still really like to know how I could fix this problem even more.  The GUIs for Python version 2.2 and below run fine for me.  

I am using Windows XP Home Edition Service Pack 2.


msg30747 - (view) Author: Kurt B. Kaiser (kbk) * (Python committer) Date: 2006-12-07 05:53
I have not seen anything like this myself on W2K or WinXP, nor have I heard of something like this before.  We switched to the subprocess version of IDLE at 2.3.  When printing a mass of text to the Shell window, IDLE is about 30% slower when using the subprocess, but that doesn't sound like what you are reporting.

When I move IDLE's windows around there is no perceptible delay, nor can I detect any slowness when typing. (The 30% isn't involved when doing that).  I can run 

i = 1
while True: 
    i +=1 
    print i

and the GUI responds quickly even though the cpu is near 100%.

If the solution works for you, fine, but it seems likely to me that there is something misconfigured with your Windows installation or that it is compromised by spyware or otherwise overloaded or having a hardware problem.

I'm setting this bug as pending, works for me unless you can come up with something more definitive.  What does your Task Manager show for CPU utilization when you are having this problem?  It seems that something is hogging your cpu or you have a very slow computer. What's the clock rate and memory size?

If you are running an internal firewall, try disconnecting from the net and turn off the firewall temporarily to see if the problem is there.
msg30748 - (view) Author: g4rlik (g4rlik) Date: 2006-12-08 00:14
I ran some programs to get rid of adaware and spyware and then tried to run the GUI for 2.5.  I still have the problem.  After that I unplugged my router (which has the internal firewall) and attempted to test the GUI's speed again.  It was still sluggish.

When running the GUI and looking in Task Manager, it uses <1% of my CPU's power.  

By the way, the specs for my computer are:

AMD Athlon XP 2800+ (2.08ghz)
1 gig RAM

I don't have an amazing rig, but that should do more than fine for running Python.  I don't believe my CPU and RAM are my problems.

Oh well, I don't think there is much more looking into this that I can do.  I'll either have to live with the sluggishness or run Python 2.2.  

Thanks.
msg30749 - (view) Author: Kurt B. Kaiser (kbk) * (Python committer) Date: 2006-12-08 05:13
Your system is powerful enough, by an order of magnitude :-)

My W2K system is about 400 Mhz.  It shows no slowdown with 2.3 - 2.5.

If your system is slow only with the subprocess, there must be something about using the socket interface that is problematic.  I don't know much about XP Home, but I vaguely recollect hearing about some difficulties with it.  You might try upgrading to Win XP Pro, or install Linux.
msg30750 - (view) Author: g4rlik (g4rlik) Date: 2006-12-08 21:51
I'd just like to say thanks for looking into the problem.  As for now, I can either deal with it or use Python 2.2, it's no problem.  
msg30751 - (view) Author: Kurt B. Kaiser (kbk) * (Python committer) Date: 2006-12-08 22:21
OK, I'll close this for now.  Feel free to reopen it if you come up with something definitive and/or can find others having the same problem.  Can you give me a link to the discussion on help@python.org?
msg30752 - (view) Author: g4rlik (g4rlik) Date: 2006-12-09 02:54
I'm not exactly sure how I'd give you a link to the discussion on help@python.org.  I was talking via e-mail and I'm not sure how to link that.  Would you want me to copy and paste it?
msg30753 - (view) Author: Kurt B. Kaiser (kbk) * (Python committer) Date: 2006-12-09 04:42
Yes, please do.
msg30754 - (view) Author: g4rlik (g4rlik) Date: 2006-12-09 15:19
Here are some important bits from the first e-mails.

"Dear Will,

> Hello there.  I'll keep this short and sweet for you, seeing as
> you're a volunteer (thank you by the way!).

Hello! We're glad to help.

> The Python GUI for versions 2.3, 2.4, and 2.5 are very slow on my
> computer. Whenever I type in the GUI or simply move the GUI around
> my desktop, its response time is slower than normal.  However, the
> GUIs of Python versions 2.2 and below are not slow at all for me.

I'm not at all sure, but the timing suggests that the problem may be
in IDLE's using a subprocess. If that's the explanation, you should
see something different if you start IDLE without a subprocess. You
ought to be able to do that by opening a command-shell window and
typing something like:

c:\python25\python c:\python25\Lib\idlelib\idle.py -n

Of course, your directory names may be different.

If that does improve IDLE's performance, that still leaves the
question of why a subprocess performs much worse on your computer
than on most people's.

Let us know what you get. Someone else here may have a different idea
or a better idea about that one.

Regards,
Matt"

"I'm a trifle curious why a loopback network connection and a
subprocess should load your machine so much, but I doubt that it
would be easy to figure that out by email."




History
Date User Action Args
2022-04-11 14:56:21adminsetgithub: 44311
2006-12-06 23:44:23g4rlikcreate