From: David W. <wo...@cs...> - 2008-02-26 17:25:09
|
Ok, I've attached a patch which adds a MarkdownException class and then raises it at a few opportune moments. I've also added a bit of checking on the -s argument. What do you think? On 26-Feb-08, at 12:04 PM, David Wolever wrote: > On 26-Feb-08, at 3:39 AM, Yuri Takhteyev wrote: >> I think the thing to do here is to raise an exception, the only >> question is what to call it. MarkdownException would be reasonable, >> though perhaps something more specific would make more sense? > I'd say MarkdownException is pretty clear :) > > Then, to make the command-line people happy, the "if __name__ == > "__main__":..." code could be wrapped in a "try: ... except > MarkdownException: ... except Exception: ..." so users don't get > tracebacks on MarkdownExceptions. |