mirror of
https://github.com/ceph/ceph
synced 2025-01-30 06:53:38 +00:00
mgr/dashboard: Exception.message doesn't exist on Python 3
Signed-off-by: Ricardo Marques <rimarques@suse.com>
This commit is contained in:
parent
49f4614cc7
commit
d7916e6458
@ -65,8 +65,8 @@ class Osd(RESTController):
|
||||
histogram = CephService.send_command('osd', srv_spec=svc_id,
|
||||
prefix='perf histogram dump')
|
||||
except SendCommandError as e:
|
||||
if 'osd down' in e.message:
|
||||
histogram = e.message
|
||||
if 'osd down' in str(e):
|
||||
histogram = str(e)
|
||||
else:
|
||||
raise
|
||||
|
||||
@ -173,7 +173,7 @@ class Osd(RESTController):
|
||||
return {'safe-to-destroy': True}
|
||||
except SendCommandError as e:
|
||||
return {
|
||||
'message': e.message,
|
||||
'message': str(e),
|
||||
'safe-to-destroy': False,
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user