Re: Hiding tracebacks from end-users

2007-10-24 Thread Matthew Woodcraft
Steven D'Aprano <[EMAIL PROTECTED]> wrote: > I'm writing a command-line application that is meant to be relatively > user friendly to non-technical users. > Consequently, I'd like to suppress Python's tracebacks if an error does > occur, replacing it with a more friendly error message. I'm doin

Re: Hiding tracebacks from end-users

2007-10-23 Thread Alan Meyer
On Oct 23, 12:07 pm, Steven D'Aprano <[EMAIL PROTECTED] cybersource.com.au> wrote: ... > if expert_mode: > # experts get the full traceback with no hand-holding. > raise > else: > # print a more friendly error message ... Another approach is to always print a frien

Re: Hiding tracebacks from end-users

2007-10-23 Thread kyosohma
On Oct 23, 11:07 am, Steven D'Aprano <[EMAIL PROTECTED] cybersource.com.au> wrote: > I'm writing a command-line application that is meant to be relatively > user friendly to non-technical users. > > (Some wags might like to say that "user friendly" and "command-line > application" are, by definitio

Re: Hiding tracebacks from end-users

2007-10-23 Thread myonov
On Oct 23, 7:07 pm, Steven D'Aprano <[EMAIL PROTECTED] cybersource.com.au> wrote: > I'm writing a command-line application that is meant to be relatively > user friendly to non-technical users. > > (Some wags might like to say that "user friendly" and "command-line > application" are, by definition

Hiding tracebacks from end-users

2007-10-23 Thread Steven D'Aprano
I'm writing a command-line application that is meant to be relatively user friendly to non-technical users. (Some wags might like to say that "user friendly" and "command-line application" are, by definition, contradictory. I disagree.) Consequently, I'd like to suppress Python's tracebacks if