Remove six from VMWare drivers

Change-Id: I26f1caebae29206442d75c8620a28517d42fc78f
This commit is contained in:
Takashi Kajinami 2024-02-01 21:18:49 +09:00
parent 2a18843ab9
commit e9a8c85cb3
2 changed files with 3 additions and 5 deletions

View File

@ -25,7 +25,6 @@ from oslo_utils import versionutils
from oslo_vmware import exceptions
from oslo_vmware import image_transfer
from oslo_vmware import vim_util
import six
from cinder import context
from cinder import exception as cinder_exceptions
@ -1155,7 +1154,7 @@ class VMwareVcVmdkDriverTestCase(test.TestCase):
rp = mock.sentinel.rp
folder = mock.sentinel.folder
# NOTE(mriedem): The summary.name gets logged so it has to be a string
summary = mock.Mock(name=six.text_type(mock.sentinel.ds_name))
summary = mock.Mock(name=str(mock.sentinel.ds_name))
select_ds_for_volume.return_value = (host, rp, folder, summary)
profile_id = mock.sentinel.profile_id

View File

@ -18,14 +18,13 @@ Implements operations on volumes residing on VMware datastores.
"""
import json
import urllib
from oslo_log import log as logging
from oslo_utils import units
from oslo_vmware import exceptions
from oslo_vmware.objects import datastore as ds_obj
from oslo_vmware import vim_util
import six
from six.moves import urllib
from cinder.i18n import _
from cinder.volume.drivers.vmware import exceptions as vmdk_exceptions
@ -1652,7 +1651,7 @@ class VMwareVolumeOps(object):
self._session.vim,
'CopyDatastoreFile_Task',
self._session.vim.service_content.fileManager,
sourceName=six.text_type(src_path),
sourceName=str(src_path),
sourceDatacenter=src_dc_ref,
destinationName=dest_ds_file_path,
destinationDatacenter=dest_dc_ref)