]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
pybind/ceph_daemon: correct type annotation of admin_socket()
authorKefu Chai <kchai@redhat.com>
Sat, 5 Jun 2021 03:53:03 +0000 (11:53 +0800)
committerKefu Chai <kchai@redhat.com>
Sat, 5 Jun 2021 03:53:08 +0000 (11:53 +0800)
we always pass a list of string to it, but since it does not assume the
container type of string, just specify Sequence[str].

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/pybind/ceph_daemon.py

index 6c87ecc207837548c63f2e926379c98aa8f95128..6ad16f4eb308e0e8c1d530f869cddbf6face12a1 100644 (file)
@@ -31,7 +31,7 @@ READ_CHUNK_SIZE = 4096
 
 
 def admin_socket(asok_path: str,
-                 cmd: str,
+                 cmd: Sequence[str],
                  format: Optional[str] = '') -> bytes:
     """
     Send a daemon (--admin-daemon) command 'cmd'.  asok_path is the