From: Sage Weil Date: Fri, 4 Oct 2019 19:30:56 +0000 (-0500) Subject: mgr/ssh: clean up bare except: block X-Git-Tag: v15.1.0~1313^2~7 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=7063934b9e352aef4a7514b4b65d8c1cae724fdd;p=ceph.git mgr/ssh: clean up bare except: block Signed-off-by: Sage Weil --- diff --git a/src/pybind/mgr/ssh/module.py b/src/pybind/mgr/ssh/module.py index 6d933261d5ac..5ec57dfd8510 100644 --- a/src/pybind/mgr/ssh/module.py +++ b/src/pybind/mgr/ssh/module.py @@ -135,8 +135,9 @@ class SSHOrchestrator(MgrModule, orchestrator.Orchestrator): try: with open(path, 'r') as f: self._ceph_daemon = f.read() - except: - raise RuntimeError("unable to read ceph-daemon at '%s'" % path) + except IOError as e: + raise RuntimeError("unable to read ceph-daemon at '%s': %s" % ( + path, str(e))) self._worker_pool = multiprocessing.pool.ThreadPool(1)