From bbefa48fd749858c80f2cd44c9f00bed75bbeb13 Mon Sep 17 00:00:00 2001 From: Joel Andres Granados Date: Tue, 15 Jul 2008 22:23:48 +0200 Subject: Be a bit less apocaliptic when telling the user that we have an unexpected exception. --- firstaidkit | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/firstaidkit b/firstaidkit index a32c3ea..f266f1f 100755 --- a/firstaidkit +++ b/firstaidkit @@ -333,16 +333,21 @@ if __name__=="__main__": try: singlerun.run() + except InvalidPluginNameException, ipne: print(ipne) + except Exception, e: - print("!!! Impossible happened!! The First Aid Kit crashed in " - "very unsafe way.\n!!! Please report this to the authors " - "along with the following message. You can create a ticket " - "at https://fedorahosted.org/firstaidkit/newticket\n\n") + # This is when an unexpected exception occurs. This usally + # means there is a bug somewhere. + print("!!! The First Aid Kit crashed in very unsafe way.\n!!! " + "Please report this to the authors along with the " + "following message. You can create a ticket at " + "https://fedorahosted.org/firstaidkit/newticket\n\n") Config.write(sys.stdout) print("Description of the error:\nError message:%s\n " \ "Error class %s"% (e, e.__class__)) + finally: singlerun.end() -- cgit