]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/dashboard: Catch LookupError when checking the RGW status 24028/head
authorVolker Theile <vtheile@suse.com>
Tue, 11 Sep 2018 10:37:28 +0000 (12:37 +0200)
committerVolker Theile <vtheile@suse.com>
Tue, 11 Sep 2018 10:48:55 +0000 (12:48 +0200)
This exception is thrown by the RGW client function _determine_rgw_addr(). Without catching that exception a 'The server encountered an unexpected condition which prevented it from fulfilling the request.' will be displayed in the UI instead of displaying a notification panel with a hint that the Object Gateway is not running.

Fixes: https://tracker.ceph.com/issues/35921
Signed-off-by: Volker Theile <vtheile@suse.com>
src/pybind/mgr/dashboard/controllers/rgw.py

index 71097919aed5c16c9ff92e62b71df2dd48f752fc..4576b97d81d3a4350eae71f5770a751eb88e3c12 100644 (file)
@@ -38,7 +38,7 @@ class Rgw(BaseController):
                     instance.userid)
                 raise RequestException(status['message'])
             status['available'] = True
-        except RequestException:
+        except (RequestException, LookupError):
             pass
         return status