jdiazbb / rfxcmd

Automatically exported from code.google.com/p/rfxcmd
1 stars 0 forks source link

Shutdown error when running as a daemon #9

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Hi,

While running in daemon mode with the default provided config.xml, there is a 
backtrace generated.
In line 208, replacing 'config.pidfile' by 'cmdarg.pidfile' makes things OK.
(line 208: logdebug("Removing PID file " + str(config.pidfile))

./rfxcmd.py -v
RFXCMD Version: 0.21
$Date: 2012-11-28 17:49:25 +0100 (Wed, 28 Nov 2012) $
$Rev: 153 $

./rfxcmd.py -c -z -d /dev/rfxcom -p /tmp/rfxcmd.pid

Some output produced (OK):
2012-12-28 07:49:02;56;02;00;E6;00;22;0.0;0.0;0;0;9;3
2012-12-28 07:49:06;50;01;00;0C;02;19.8;9;5
2012-12-28 07:49:16;56;02;00;E6;00;22;0.0;0.0;0;0;9;3
2012-12-28 07:49:29;52;02;00;D3;01;11.6;96;3;9;5
2012-12-28 07:49:30;56;02;00;E6;00;22;0.0;0.0;0;0;9;3
2012-12-28 07:49:31;55;02;00;C1;00;0;0;9;4

Then, using kill <rfxcmdpid> got from /tmp/rfxcmd.pid:

Traceback (most recent call last):
  File "./rfxcmd.py", line 2403, in <module>
    rawcmd = read_rfx()
  File "./rfxcmd.py", line 1596, in read_rfx
    byte = serialport.read()
  File "build/bdist.linux-armv5tel/egg/serial/serialposix.py", line 446, in read
  File "./rfxcmd.py", line 217, in handler
    shutdown()
  File "./rfxcmd.py", line 208, in shutdown
    logdebug("Removing PID file " + str(config.pidfile))
AttributeError: config_data instance has no attribute 'pidfile'

Original issue reported on code.google.com by skim...@gmail.com on 28 Dec 2012 at 7:08

GoogleCodeExporter commented 8 years ago
This will be fixed in version 0.22, thanks for the report.

Original comment by sebastia...@gmail.com on 31 Dec 2012 at 10:07

GoogleCodeExporter commented 8 years ago
Fixed in 0.22

Original comment by sebastia...@gmail.com on 2 Jan 2013 at 11:33