codestyle docstrings

This commit is contained in:
2017-04-11 12:48:19 +02:00
parent b26fbc2dc0
commit 38f67e2b83
3 changed files with 7 additions and 4 deletions

View File

@@ -202,7 +202,7 @@ Methods</h3>
<td>Instantiiert PipeLogwriter-Klasse.</td>
</tr><tr>
<td><a style="color:#0000FF" href="#PipeLogwriter.__del__">__del__</a></td>
<td></td>
<td>Close file handler.</td>
</tr><tr>
<td><a style="color:#0000FF" href="#PipeLogwriter._configurefh">_configurefh</a></td>
<td>Konfiguriert den FileHandler fuer Ausgaben der PLCAPP.</td>
@@ -240,7 +240,9 @@ Dateiname fuer Logdatei
<h3 style="background-color:#FFFFFF;color:#FF0000">
PipeLogwriter.__del__</h3>
<b>__del__</b>(<i></i>)
<a NAME="PipeLogwriter._configurefh" ID="PipeLogwriter._configurefh"></a>
<p>
Close file handler.
</p><a NAME="PipeLogwriter._configurefh" ID="PipeLogwriter._configurefh"></a>
<h3 style="background-color:#FFFFFF;color:#FF0000">
PipeLogwriter._configurefh</h3>
<b>_configurefh</b>(<i></i>)

View File

@@ -63,7 +63,7 @@ def configure():
pargs.conffile = os.path.join(startdir, pargs.conffile)
if pargs.logfile is not None and os.path.dirname(pargs.logfile) == "":
pargs.logfile = os.path.join(startdir, pargs.logfile)
# Prüfen ob als Daemon ausgeführt werden soll
global forked
pidfile = "/var/run/revpipyload.pid"

View File

@@ -192,6 +192,7 @@ class PipeLogwriter(Thread):
))
def __del__(self):
"""Close file handler."""
if self._fh is not None:
self._fh.close()
@@ -305,7 +306,7 @@ class RevPiPlc(Thread):
elif proginit.pargs.logfile is not None:
logfile = proginit.pargs.logfile
if not logfile is None:
if logfile is not None:
logfile = PipeLogwriter(logfile)
proginit.logger.debug("leave RevPiPlc._configureplw()")