From 7dfba6b43d3d185472b03a4bed53c9e2615db06a Mon Sep 17 00:00:00 2001 From: Oliver Smith Date: Mon, 3 Nov 2014 14:12:30 -0800 Subject: [PATCH] Unqualified exceptions in commands/__init__.py --- commands/__init__.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/commands/__init__.py b/commands/__init__.py index 40e077d0..f6f33b82 100644 --- a/commands/__init__.py +++ b/commands/__init__.py @@ -21,7 +21,7 @@ class HelpAction(argparse.Action): because Python 3.4's argparse is ever-so subtly very broken. """ def __call__(self, parser, namespace, values, option_string=None): - raise UsageError("TradeDangerous help", parser.format_help()) + raise exceptions.UsageError("TradeDangerous help", parser.format_help()) def addArguments(group, options, required, topGroup=None): @@ -108,7 +108,9 @@ def usage(self, argv): def parse(self, argv): if len(argv) <= 1 or argv[1] == '--help' or argv[1] == '-h': - raise UsageError("TradeDangerous provides a set of Trade Database facilities for Elite:Dangerous.", self.usage(argv)) + raise exceptions.UsageError( + "TradeDangerous provides a set of trade database " + "facilities for Elite:Dangerous.", self.usage(argv)) ### TODO: Break this model up a bit more so that ### we just try and import the command you specify,