]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mgr/volumes/nfs: Fix mypy errors
authorVarsha Rao <varao@redhat.com>
Tue, 24 Mar 2020 18:56:56 +0000 (00:26 +0530)
committerVarsha Rao <varao@redhat.com>
Wed, 8 Apr 2020 11:51:17 +0000 (17:21 +0530)
commitb87f6fc0fd1cdc5803166a2f92ce5152d5495999
tree9349ec3d3aeed2a0257c324ae5e37e6fd3c8998c
parent75c5a8bfb27cff8975b6c062ddac1a38bd117b9b
mgr/volumes/nfs: Fix mypy errors

This patch fixes the following mypy errors:
volumes/module.py:9: note: In module imported here,
volumes/__init__.py:2: note: ... from here:
volumes/fs/nfs.py: note: In member "validate_path" of class "CephFSFSal":
volumes/fs/nfs.py:80: error: Name 're' is not defined
volumes/fs/nfs.py: note: In member "create_path" of class "CephFSFSal":
volumes/fs/nfs.py:83: error: Name 'CephFS' is not defined
volumes/fs/nfs.py: note: In member "_persist_daemon_configuration" of class "GaneshaConf":
volumes/fs/nfs.py:259: error: Need type annotation for 'daemon_map' (hint: "daemon_map: Dict[<type>, <type>] = ...")
volumes/fs/nfs.py: note: In member "create_instance" of class "NFSConfig":
volumes/fs/nfs.py:386: error: Incompatible types in assignment (expression has type "GaneshaConf", variable has type "str")
volumes/fs/nfs.py: note: In member "create_export" of class "NFSConfig":
volumes/fs/nfs.py:389: error: "str" has no attribute "create_export"
volumes/fs/nfs.py: note: In member "delete_export" of class "NFSConfig":
volumes/fs/nfs.py:404: error: "str" has no attribute "has_export"
volumes/fs/nfs.py:407: error: "str" has no attribute "remove_export"
volumes/fs/nfs.py:408: error: "str" has no attribute "reload_daemons"
volumes/__init__.py:2: note: In module imported here:
volumes/module.py: note: In member "_cmd_fs_nfs_export_create" of class "Module":
volumes/module.py:406: error: "str" has no attribute "check_fsal_valid"
volumes/module.py:407: error: "str" has no attribute "create_instance"
volumes/module.py:408: error: "str" has no attribute "create_export"
volumes/module.py: note: In member "_cmd_fs_nfs_export_delete" of class "Module":
volumes/module.py:412: error: "str" has no attribute "delete_export"
volumes/module.py: note: In member "_cmd_fs_nfs_cluster_create" of class "Module":
volumes/module.py:415: error: Incompatible types in assignment (expression has type "NFSConfig", variable has type "str")
volumes/module.py:416: error: "str" has no attribute "create_nfs_cluster"

Signed-off-by: Varsha Rao <varao@redhat.com>
src/pybind/mgr/volumes/fs/nfs.py
src/pybind/mgr/volumes/module.py