From e2d66aaa670817bda9bf1b494b6a4cfde32b6daf Mon Sep 17 00:00:00 2001 From: Anthony Young Date: Thu, 17 Mar 2011 14:28:03 -0700 Subject: fix for lp712982, and likely a variety of other dashboard error handling issues. This fix simply causes the default error code for ApiError to be 'ApiError' rather than 'Unknown', which makes dashboard handle the error gracefully, and makes euca error output slightly prettier --- nova/exception.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'nova/exception.py') diff --git a/nova/exception.py b/nova/exception.py index 93c5fe3d7..4e2bbdbaf 100644 --- a/nova/exception.py +++ b/nova/exception.py @@ -46,7 +46,7 @@ class Error(Exception): class ApiError(Error): - def __init__(self, message='Unknown', code='Unknown'): + def __init__(self, message='Unknown', code='ApiError'): self.message = message self.code = code super(ApiError, self).__init__('%s: %s' % (code, message)) -- cgit