From: Jack Jansen Date: Mon, 5 Aug 2002 21:14:16 +0000 (+0000) Subject: Better output for errors, and some progress reports. X-Git-Tag: v2.3c1~4686 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=20417bcd180e1a3e6a95b1a116956bc5ebecba7d;p=python Better output for errors, and some progress reports. Handle the two modules with non-standard scanner module names. --- diff --git a/Mac/scripts/bgenall.py b/Mac/scripts/bgenall.py index 8fe36aa5f9..6490265ebc 100644 --- a/Mac/scripts/bgenall.py +++ b/Mac/scripts/bgenall.py @@ -6,13 +6,24 @@ import string def bgenone(dirname, shortname): os.chdir(dirname) + print '%s:'%shortname + # Sigh, we don't want to lose CVS history, so two + # modules have funny names: + if shortname == 'carbonevt': + modulename = 'CarbonEvtscan' + elif shortname == 'ibcarbon': + modulename = 'IBCarbonscan' + else: + modulename = shortname + 'scan' try: - m = __import__(shortname+'scan') + m = __import__(modulename) except: + print "Error:", shortname, sys.exc_info()[1] return 0 try: m.main() except: + print "Error:", shortname, sys.exc_info()[1] return 0 return 1