Modul8 catches exceptions without letting us know
Posted: Mon Dec 22, 2008 8:25 pm
Bonjour,
I have been doing intensive development in Python with Modul8 recently, and I can say it is very difficult. Modul8's IDE didn't make my life easy at all.
It seems like Modul8 sometimes catches exceptions (errors) without printing anything to the console or popping up an error window. After a lot of hours trying to find out why some parts of my code were not executed, I finally ended up with a solution like this:
Is is not very elegant to catch any type of exceptions, but it might be very useful when your code does a lot of things.
If we don't use the try statement like this, some parts of our code will never be executed, silently, if an exception happens.
I think there should be something printed in the error console if an exception happens, instead of not letting the programmer know.
Thank you,
I have been doing intensive development in Python with Modul8 recently, and I can say it is very difficult. Modul8's IDE didn't make my life easy at all.

It seems like Modul8 sometimes catches exceptions (errors) without printing anything to the console or popping up an error window. After a lot of hours trying to find out why some parts of my code were not executed, I finally ended up with a solution like this:
Code: Select all
import sys
try:
pass # do whatever you need to do here (all your code)
except:
print "An error happened ! ", sys.exc_info()
raise Exception,"Stopping the module, since a bug is found"+str(sys.exc_info())
Is is not very elegant to catch any type of exceptions, but it might be very useful when your code does a lot of things.
If we don't use the try statement like this, some parts of our code will never be executed, silently, if an exception happens.
I think there should be something printed in the error console if an exception happens, instead of not letting the programmer know.
Thank you,