From 6cd159334b3d23e515926a566c751f1fc006bfe9 Mon Sep 17 00:00:00 2001 From: Thomas Gerigk Date: Mon, 3 Apr 2006 18:54:45 +0200 Subject: [PATCH] Catch AttributeError when a command has no help() def'd. --- becommands/help.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/becommands/help.py b/becommands/help.py index fc89207..2f37ec2 100644 --- a/becommands/help.py +++ b/becommands/help.py @@ -27,7 +27,11 @@ def execute(args): for name, module in cmdutil.iter_commands(): print "be %s\n %s" % (name, module.__doc__) else: - print cmdutil.help(args[0]) + try: + print cmdutil.help(args[0]) + except AttributeError: + print "No help available" + return -- 2.26.2