From: Kefu Chai Date: Thu, 14 Jan 2021 17:26:13 +0000 (+0800) Subject: pybind/mgr/mgr_module: annotate some methods X-Git-Tag: v16.1.0~20^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=b70f36bf91af187b51aae7830223cc49b3cd4325;p=ceph-ci.git pybind/mgr/mgr_module: annotate some methods as a vehicle to understand the interface Signed-off-by: Kefu Chai --- diff --git a/src/pybind/mgr/mgr_module.py b/src/pybind/mgr/mgr_module.py index b57efed0588..7a0a5897aa3 100644 --- a/src/pybind/mgr/mgr_module.py +++ b/src/pybind/mgr/mgr_module.py @@ -1264,13 +1264,13 @@ class MgrModule(ceph_module.BaseMgrModule, MgrModuleLoggingMixin): """ self._ceph_set_health_checks(checks) - def _handle_command(self, inbuf, cmd): + def _handle_command(self, inbuf: str, cmd: Dict[str, Any]): if cmd['prefix'] not in CLICommand.COMMANDS: return self.handle_command(inbuf, cmd) return CLICommand.COMMANDS[cmd['prefix']].call(self, cmd, inbuf) - def handle_command(self, inbuf, cmd): + def handle_command(self, inbuf: str, cmd: Dict[str, Any]): """ Called by ceph-mgr to request the plugin to handle one of the commands that it declared in self.COMMANDS