]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
pybind/mgr: keep the docstring of func wrapped by CLICheckNonemptyFileInput
authorKefu Chai <kchai@redhat.com>
Sat, 26 Dec 2020 09:34:30 +0000 (17:34 +0800)
committerKefu Chai <kchai@redhat.com>
Sun, 27 Dec 2020 14:50:10 +0000 (22:50 +0800)
Signed-off-by: Kefu Chai <kchai@redhat.com>
src/pybind/mgr/mgr_module.py

index 66e3f4caf734c44487ff6cbeb5647c8f32b5d354..99ff3647f9b6cced396b657e3ec5766a429fe332 100644 (file)
@@ -12,6 +12,7 @@ if TYPE_CHECKING:
 
 import logging
 import errno
+import functools
 import json
 import threading
 from collections import defaultdict, namedtuple
@@ -359,6 +360,7 @@ def CLIWriteCommand(prefix, args="", desc=""):
 
 
 def CLICheckNonemptyFileInput(func):
+    @functools.wraps(func)
     def check(*args, **kwargs):
         if not 'inbuf' in kwargs:
             return -errno.EINVAL, '', ERROR_MSG_NO_INPUT_FILE