Bugs item #1650899, was opened at 2007-02-02 21:27 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1650899&group_id=5470
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Python Interpreter Core Group: Python 2.5 Status: Open Resolution: None Priority: 5 Private: No Submitted By: Miki Tebeka (tebeka) Assigned to: Nobody/Anonymous (nobody) Summary: sys.excepthook does not work with -m command line switch Initial Comment: crashlog.py is the following: import sys def excepthook(type, value, traceback): print "BUMMER" sys.excepthook = excepthook When crash.py is like: import crashlog raise ValueError("so sad") The it works as expected: [EMAIL PROTECTED] - 11:22] ~ $python crash.py BUMMER [EMAIL PROTECTED] - 11:23] ~ $ However when I try to load crashlog using -m and leave crash.py like: raise ValueError("so sad") The nothing (not even original excepthook is called): [EMAIL PROTECTED] - 11:23] ~ $python -m crashlog crash.py [EMAIL PROTECTED] - 11:25] ~ $ ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1650899&group_id=5470 _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com