Enable pylint useless-super-delegation check
Change code to remove unneeded super() calls. In the case of the MaintenanceWorker class, the parent classes never implement anything for stop() or wait() so we can safely use 'pass'. They must exist since the oslo.service class defines them as abtract methods. TrivialFix Change-Id: Ic8b184f077b6647c735e01cf89211f1fc613cb85
This commit is contained in:
parent
98247364f2
commit
822edc31c8
@ -47,7 +47,6 @@ disable=
|
|||||||
unused-argument,
|
unused-argument,
|
||||||
unused-import,
|
unused-import,
|
||||||
unused-variable,
|
unused-variable,
|
||||||
useless-super-delegation,
|
|
||||||
unnecessary-pass,
|
unnecessary-pass,
|
||||||
raise-missing-from,
|
raise-missing-from,
|
||||||
arguments-renamed,
|
arguments-renamed,
|
||||||
|
@ -103,9 +103,6 @@ def _add_gateway_chassis(api, txn, lrp_name, val):
|
|||||||
|
|
||||||
|
|
||||||
class CheckLivenessCommand(command.BaseCommand):
|
class CheckLivenessCommand(command.BaseCommand):
|
||||||
def __init__(self, api):
|
|
||||||
super().__init__(api)
|
|
||||||
|
|
||||||
def run_idl(self, txn):
|
def run_idl(self, txn):
|
||||||
# txn.pre_commit responsible for updating nb_global.nb_cfg, but
|
# txn.pre_commit responsible for updating nb_global.nb_cfg, but
|
||||||
# python-ovs will not update nb_cfg if no other changes are made
|
# python-ovs will not update nb_cfg if no other changes are made
|
||||||
|
@ -234,9 +234,6 @@ def get_ovn_idls(driver, trigger):
|
|||||||
|
|
||||||
|
|
||||||
class OvsdbNbOvnIdl(nb_impl_idl.OvnNbApiIdlImpl, Backend):
|
class OvsdbNbOvnIdl(nb_impl_idl.OvnNbApiIdlImpl, Backend):
|
||||||
def __init__(self, connection):
|
|
||||||
super().__init__(connection)
|
|
||||||
|
|
||||||
@n_utils.classproperty
|
@n_utils.classproperty
|
||||||
def connection_string(cls):
|
def connection_string(cls):
|
||||||
return cfg.get_ovn_nb_connection()
|
return cfg.get_ovn_nb_connection()
|
||||||
@ -913,9 +910,6 @@ class OvsdbNbOvnIdl(nb_impl_idl.OvnNbApiIdlImpl, Backend):
|
|||||||
|
|
||||||
|
|
||||||
class OvsdbSbOvnIdl(sb_impl_idl.OvnSbApiIdlImpl, Backend):
|
class OvsdbSbOvnIdl(sb_impl_idl.OvnSbApiIdlImpl, Backend):
|
||||||
def __init__(self, connection):
|
|
||||||
super().__init__(connection)
|
|
||||||
|
|
||||||
@n_utils.classproperty
|
@n_utils.classproperty
|
||||||
def connection_string(cls):
|
def connection_string(cls):
|
||||||
return cfg.get_ovn_sb_connection()
|
return cfg.get_ovn_sb_connection()
|
||||||
|
@ -31,11 +31,11 @@ class MaintenanceWorker(worker.BaseWorker):
|
|||||||
|
|
||||||
def stop(self):
|
def stop(self):
|
||||||
"""Stop service."""
|
"""Stop service."""
|
||||||
super().stop()
|
pass
|
||||||
|
|
||||||
def wait(self):
|
def wait(self):
|
||||||
"""Wait for service to complete."""
|
"""Wait for service to complete."""
|
||||||
super().wait()
|
pass
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def reset():
|
def reset():
|
||||||
|
Loading…
x
Reference in New Issue
Block a user