]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
pybind/mgr/mgr_module: drop py2 support
authorKefu Chai <kchai@redhat.com>
Sun, 28 Jun 2020 12:52:35 +0000 (20:52 +0800)
committerKefu Chai <kchai@redhat.com>
Sun, 5 Jul 2020 02:58:29 +0000 (10:58 +0800)
Signed-off-by: Kefu Chai <kchai@redhat.com>
src/pybind/mgr/mgr_module.py

index 49c94826b3a8b04fa2185d9726bdb11e7b27011f..8dedef44d95e94f6a174527ccf10425babb6e375 100644 (file)
@@ -8,7 +8,6 @@ except ImportError:
 import logging
 import errno
 import json
-import six
 import threading
 from collections import defaultdict, namedtuple
 import rados
@@ -197,7 +196,7 @@ class CRUSHMap(ceph_module.BasePyCRUSH):
 
     def get_take_weight_osd_map(self, root):
         uglymap = self._get_take_weight_osd_map(root)
-        return {int(k): v for k, v in six.iteritems(uglymap.get('weights', {}))}
+        return {int(k): v for k, v in uglymap.get('weights', {}).items()}
 
     @staticmethod
     def have_default_choose_args(dump):