0

I've had a strange occurance. I stopped a python script manually, but its still running. It shows it as stopped in my IDE (Spyder) but I can see it's still running in task manager. I also know it still processing because its still outputting files to a directory.

Does anyone know why this is happening and how I can prevent it on a go forward?

task

Valentin Lorentz
  • 9,556
  • 6
  • 47
  • 69
  • close the process and run your code again. does it happens again? – dot.Py May 18 '16 at 18:03
  • Tell me more about how you wrote your job – gerosalesc May 18 '16 at 18:05
  • @gerosalesc I think i found an incorrectly written if / pass / else. Could that have caused it? Even so, if you stop it manually shouldn't that stop it regardless of what's going on in the script? –  May 18 '16 at 18:40
  • @Dot_Py i think its inconsistant based upon when i stop it. In particular, the record i stop it on which could be a factor of the error / exception handling i mentioned in my comment to gerosalesc –  May 18 '16 at 18:41

1 Answers1

1

Got it, i needed to add Exception to my except statement. Thanks gerosalesc and Dot_Py for your help.

Try/Except in Python: How do you properly ignore Exceptions?

Community
  • 1
  • 1