[elbe-devel] [PATCH 2/5] daemons: soap: datatypes: remove unnecessary __init__ functions
Torben Hohn
torben.hohn at linutronix.de
Wed Sep 8 17:01:35 CEST 2021
pylint complains:
************* Module elbepack.daemons.soap.datatypes
/home/elbe/devel/elbepack/daemons/soap/datatypes.py:20:4: W0231: __init__ method from base class 'ComplexModel' is not called (super-init-not-called)
/home/elbe/devel/elbepack/daemons/soap/datatypes.py:34:4: W0231: __init__ method from base class 'ComplexModel' is not called (super-init-not-called)
The classes are only used as return types, and spyne can automatically
do the conversion.
Just remove the __init__() functions.
Note that for SoapCmdReply the constructor is needed.
Signed-off-by: Torben Hohn <torben.hohn at linutronix.de>
---
elbepack/daemons/soap/datatypes.py | 11 -----------
1 file changed, 11 deletions(-)
diff --git a/elbepack/daemons/soap/datatypes.py b/elbepack/daemons/soap/datatypes.py
index bc1cb8914..7e3dafb01 100644
--- a/elbepack/daemons/soap/datatypes.py
+++ b/elbepack/daemons/soap/datatypes.py
@@ -17,13 +17,6 @@ class SoapProject (ComplexModel):
status = Unicode()
edit = DateTime()
- def __init__(self, prj):
- self.builddir = prj.builddir
- self.name = prj.name
- self.version = prj.version
- self.status = prj.status
- self.edit = prj.edit
-
class SoapFile (ComplexModel):
__namespace__ = 'soap'
@@ -31,10 +24,6 @@ class SoapFile (ComplexModel):
name = Unicode()
description = Unicode()
- def __init__(self, fi):
- self.name = fi.name
- self.description = fi.description
-
class SoapCmdReply (ComplexModel):
__namespace__ = 'soap'
--
2.20.1
More information about the elbe-devel
mailing list