try another color:
try another fontsize: 60% 70% 80% 90%
dueyesterday.net
Documentation for the masses

Python IDLE Bug

For anyone who develops with Python on Windows this post is for you. There appears to be a bug in the Windows version of IDLE that caches your code upon executing it. This is a problem because users may use IDLE to continually test their code as changes are made. This is exactly what I was doing when this issue occurred. I made changes to my code and hit F5 to run it through IDLE. The code appeared to run without any errors, but when I closed everything out and ran it again it turned out to be full of errors.

I am able to replicate this problem with my code and have seen others have the same problem, but its unclear when and what causes the caching to take place. I created a test file that only contained "print hello". I ran this, made changes and then ran it again. The changes were reflected, but after testing my code, it still cached. Attached is a simple python file I used to test everything out. Run the test, then comment out the Struct class and run again. No errors should appear, but if you close the code, reopen it and then run it again it will error.

This problem was tested on both python 2.5.2 and 2.6.1 so the issue has been with IDLE for some time. The bug has been submitted to Python's development team (http://bugs.python.org/issue4691) and hopefully a solution will come out soon.

AttachmentSize
bug-test.py.txt286 bytes
Your rating: None Average: 3.4 (5 votes)