469,279 Members | 2,200 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,279 developers. It's quick & easy.

Why do my Python scripts sometimes not run?

I'm using IDLE (Python GUI) 2.5.1

I open the Python Shell
>File
>New Window
I type in my script
>Run
>Run Module

If IDLE was just started, my script runs fine. After editing my script a few times, the Python shell sometimes just says

======= Restart =======
>>>

even though the exact same script runs fine other times.

I also noticed that when I experience this problem, and open up task manage, there are a few instances of the program running, which I have to end manually. Another problem I have when this happens is that, after exiting the Shell and editor, I have to go into task manager and close each instance of Python manually or else it won't let me start it up again.

The programming book I'm reading uses IDLE for every example, in which they encourage the reader to follow along. I wanted to be able to do that.
Jun 9 '11 #1
1 2299
bvdet
2,851 Expert Mod 2GB
"======= Restart =======" indicates the environment was restarted so your revised script can be imported. Otherwise, your script would have to be reimported with reload(). I don't know why you end up with multiple process running unless errors are not handled properly (just guessing). Try using another IDE like Pythonwin.
Jun 14 '11 #2

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

2 posts views Thread by Shufen | last post: by
8 posts views Thread by Jan Danielsson | last post: by
6 posts views Thread by Ishpeck | last post: by
24 posts views Thread by Mark | last post: by
reply views Thread by ashish | last post: by
2 posts views Thread by joe jacob | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.