[Tutor] serious problem with graphics module

Lie Ryan lie.1296 at gmail.com
Tue Jun 2 18:13:00 CEST 2009

roberto wrote:
> On Tue, May 26, 2009 at 12:45 AM, Gregor Lingl <gregor.lingl at aon.at> wrote:
>> I know one situation in which can happen what you describe:
>> If you use IDLE, issue the above commands and your Idle-shell-window
>> covers the graphics window - then you have to move the shell window in order
>> to see what's on the graphics window. Alas, in this situation the graphics
>> window may get nonresponsive (to the Windows-event-queue) and may not
>> be refreshed. So it remains apparentl empty. You may also experience
>> problems when trying to close the window (because of the same reasons).
> right !
>> *Remedy*: if you use the turtle module interactively, you have to use Idle
>> with the -n flag, which prevents it from using subprocesses for executing
>> scripts.
>> I recommend to prepare a special shortcut on your desktop, something
>> like this:
>> C:\Python30\pythonw.exe C:\Python30\Lib\idlelib\idle.pyw -n
>> When you fire up Idle with this link you will get the text:
>> ==== No Subprocess ====
>> above your first input prompt.
>> Now you can enter your commands and everything should work fine.
> ok, it works all right now
> the minor issue is that i could not create the shortcut with the -n
> flag as you pointed out, that's why i issued both commands:
> C:\Python30\pythonw.exe
> C:\Python30\Lib\idlelib\idle.pyw -n
> via the C: prompt
> and the graphic window finally worked correctly
> thank you again

Be aware though that using IDLE without subprocess also has its own
problems such as leaked variables from previous execution. Although IDLE
tries to clear itself up sometimes there are things that still leaves
various odd effects here and there especially with Tkinter itself. The
real solution would be to give up IDLE and use python from cmd.exe

More information about the Tutor mailing list