summaryrefslogtreecommitdiff
path: root/nova/virt/powervm
diff options
context:
space:
mode:
authorTakashi Natsume <takanattie@gmail.com>2020-05-10 03:00:47 +0000
committerTakashi Natsume <takanattie@gmail.com>2020-08-15 07:45:39 +0000
commit5191b4f2f00018d0273bedbc55c8a88087a25871 (patch)
treeb8d9971054e4ab62b4a0bdff93047dfc0a9ef1f6 /nova/virt/powervm
parent28ed0c5c9a7572c002e520685bed60ccc706175b (diff)
downloadnova-5191b4f2f00018d0273bedbc55c8a88087a25871.tar.gz
Remove six.add_metaclass
Replace six.add_metaclass with Python 3 style code. Change-Id: Ifc3f2bcb8fcdd2b555864bd4e22a973a7858c272 Implements: blueprint six-removal Signed-off-by: Takashi Natsume <takanattie@gmail.com>
Diffstat (limited to 'nova/virt/powervm')
-rw-r--r--nova/virt/powervm/disk/driver.py4
-rw-r--r--nova/virt/powervm/vif.py3
2 files changed, 2 insertions, 5 deletions
diff --git a/nova/virt/powervm/disk/driver.py b/nova/virt/powervm/disk/driver.py
index 63765eefb4..9e53eff89d 100644
--- a/nova/virt/powervm/disk/driver.py
+++ b/nova/virt/powervm/disk/driver.py
@@ -22,7 +22,6 @@ import pypowervm.const as pvm_const
import pypowervm.tasks.scsi_mapper as tsk_map
import pypowervm.util as pvm_u
import pypowervm.wrappers.virtual_io_server as pvm_vios
-import six
from nova import exception
from nova.virt.powervm import mgmt
@@ -61,8 +60,7 @@ class IterableToFileAdapter(object):
return return_value
-@six.add_metaclass(abc.ABCMeta)
-class DiskAdapter(object):
+class DiskAdapter(metaclass=abc.ABCMeta):
capabilities = {
'shared_storage': False,
diff --git a/nova/virt/powervm/vif.py b/nova/virt/powervm/vif.py
index af8adf740a..6662249539 100644
--- a/nova/virt/powervm/vif.py
+++ b/nova/virt/powervm/vif.py
@@ -148,8 +148,7 @@ def unplug(adapter, instance, vif, cna_w_list=None):
_push_vif_event(adapter, 'unplug', vnet_w, instance, vif['type'])
-@six.add_metaclass(abc.ABCMeta)
-class PvmVifDriver(object):
+class PvmVifDriver(metaclass=abc.ABCMeta):
"""Represents an abstract class for a PowerVM Vif Driver.
A VIF Driver understands a given virtual interface type (network). It