johnf wrote: > On Thursday 20 November 2008 08:37:28 am Paul McNett wrote: >> Just curious: why do you want your users seeing the debug output? > > I don't but in this case the user is the project manager. He wants to see > the > command prompt because he want to see the errors. He also has to report the > errors and traceback or messages back to me. At the moment he has been > reporting the error about the dataset. He wanted to know why it has not been > fixed. But of course it's not broken. I have been considering trying to > find a work around.
What I think you should do for your distributed app is override sys.__excepthook__ to catch *all* unhandled errors and show a dialog with some information and then close the app. My app defines a HandleErrors property which defaults to True if the app is frozen (py2exe or py2app), and False if not (if I'm testing). That way the user sees the error dialog, and I see the traceback. My error handler doesn't display anything technical, just a "We are sorry", and a place for the user to enter notes about what they were doing. It then connects to a webservice to send the technical information to my master error database, and closes the app. Not allowing the app to continue when an unhandled error happens is important IMO. While it does frustrate users, the problem *must* be fixed by me ASAP and because it was unhandled, it is fairly risky to let the app continue on because now the state is undefined. For the info and error logs, I reroute those to the user's AppData directory for my app, to files 'error.log' and 'info.log'. These logs reset with each app start. So a knowledgeable user could review them if they wanted. Paul _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users Searchable Archives: http://leafe.com/archives/search/dabo-users This message: http://leafe.com/archives/byMID/[EMAIL PROTECTED]
