]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
mgr/rbd_support: avoid using list of different type of elements
authorKefu Chai <kchai@redhat.com>
Thu, 18 Feb 2021 07:18:01 +0000 (15:18 +0800)
committerKefu Chai <kchai@redhat.com>
Thu, 18 Feb 2021 14:46:51 +0000 (22:46 +0800)
commit403151c83c6fd2f6923fb734f2fbd2bfb6d49b07
treee7ee27e40ca60bd2706dd9a7bb0d096900236519
parentfea6fdff4c741c8f30a2fd4a708fc369fc1c21e0
mgr/rbd_support: avoid using list of different type of elements

refactor Schedules.find() to avoid using list composed of different
types of elements. this annoys mypy.

also take this opportunity to avoid looking up in the dict twice.

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