Fix the following issue seen while upstream teuthology testing,
File "/usr/share/ceph/mgr/volumes/fs/operations/versions/subvolume_base.py", line 98, in load_config
self.metadata_mgr = MetadataManager(self.fs, self.legacy_config_path, 0o640)
File "/usr/share/ceph/mgr/volumes/fs/operations/versions/subvolume_base.py", line 73, in legacy_config_path
meta_config = "{0}.meta".format(m.digest().hex())
AttributeError: 'str' object has no attribute 'hex'
This issue is not observed in master/octopus, as it only supports
py3.
Signed-off-by: Ramana Raja <rraja@redhat.com>
def legacy_config_path(self):
m = md5()
m.update(self.base_path)
- meta_config = "{0}.meta".format(m.digest().hex())
+ meta_config = "{0}.meta".format(m.hexdigest())
return os.path.join(self.legacy_dir, meta_config.encode('utf-8'))
@property