manu-fwi / openlcb-gateway

Gateway from openlcb to cmri (and more)
GNU General Public License v3.0
3 stars 1 forks source link

RR_duino_net_serial.py: NameError: name 'pending_answer' is not defined #8

Closed ggee closed 4 years ago

ggee commented 4 years ago

Error during startup.

pi@RPi-JMRI:~/openlcb-gateway $ python3 RR_duino_net_serial.py
RR_duino_net_serial started on serial port /dev/ttyUSB0 at 38400
Connected to serial port /dev/ttyUSB0
connected to gateway!
loading RR_duino nodes from RR_duino_nodes_DB.cfg
Getting config from node at  1
Sensors list= [(1, 9, 2), (2, 4, 0)]
Turnouts list= []
Traceback (most recent call last):
  File "RR_duino_net_serial.py", line 308, in <module>
    if to_managed(ID):
  File "RR_duino_net_serial.py", line 240, in to_managed
    if not online_nodes[fullID].get_config():
  File "RR_duino_net_serial.py", line 52, in get_config
    if not pending_answer:  #reset ping time if no answer is pending, otherwise decrease by PING_TIMEOUT/5
NameError: name 'pending_answer' is not defined
ggee commented 4 years ago

Changed reference from pending_answer to pending_answers.

manu-fwi commented 4 years ago

Perfect