]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
qa/tasks/cephfs: drop six dependency
authorKefu Chai <kchai@redhat.com>
Sun, 28 Jun 2020 11:59:50 +0000 (19:59 +0800)
committerKefu Chai <kchai@redhat.com>
Sun, 5 Jul 2020 02:58:28 +0000 (10:58 +0800)
Signed-off-by: Kefu Chai <kchai@redhat.com>
qa/tasks/cephfs/test_forward_scrub.py

index 7ed8564d22887bed10b536ec1bfbbda8c69b5d63..9ca3c4de790c4ab5a6de4591c85d35e10e74398e 100644 (file)
@@ -7,10 +7,8 @@ This is *not* the real testing for forward scrub, which will need to test
 how the functionality responds to damaged metadata.
 
 """
-import json
-
 import logging
-import six
+import json
 
 from collections import namedtuple
 from io import BytesIO
@@ -37,7 +35,7 @@ class TestForwardScrub(CephFSTestCase):
         output = self.fs.rados(["getxattr", obj, attr], pool=pool,
                                stdout_data=BytesIO())
         strlen = struct.unpack('i', output[0:4])[0]
-        return six.ensure_str(output[4:(4 + strlen)], encoding='ascii')
+        return output[4:(4 + strlen)].decode(encoding='ascii')
 
     def _get_paths_to_ino(self):
         inos = {}