prebot crashing
Opened this issue · 2 comments
Deleted user commented
I have updated to the latest pynab code; I am see this traceback from the supervisor log for prebot:
Traceback (most recent call last):
File "/home/boo1234/software/pynab/prebot.py", line 60, in <module>
main()
File "/home/boo1234/software/pynab/prebot.py", line 51, in main
bot.start()
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/bot.py", line 265, in start
super(SingleServerIRCBot, self).start()
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/client.py", line 1246, in start
self.reactor.process_forever()
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/client.py", line 278, in process_forever
self.process_once(timeout)
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/client.py", line 259, in process_once
self.process_data(i)
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/client.py", line 216, in process_data
c.process_data()
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/client.py", line 582, in process_data
self._process_line(line)
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/client.py", line 614, in _process_line
handler(arguments, command, source, tags)
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/client.py", line 646, in _handle_message
self._handle_event(event)
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/client.py", line 673, in _handle_event
self.reactor._handle_event(self, event)
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/client.py", line 398, in _handle_event
result = handler.callback(connection, event)
File "/home/boo1234/.virtualenvs/pynab/lib/python3.4/site-packages/irc/client.py", line 1209, in _dispatcher
method(connection, event)
File "/home/boo1234/software/pynab/prebot.py", line 40, in on_pubmsg
pynab.pre.nzedbirc(a)
File "/home/boo1234/software/pynab/pynab/pre.py", line 11, in nzedbirc
formattedPre = parseNzedbirc(unformattedPre)
File "/home/boo1234/software/pynab/pynab/pre.py", line 42, in parseNzedbirc
if formattedPre['preType'] == "NUK":
KeyError: 'preType'
This was mentioned in #231 (comment) as well.
Edit: I noticed the following in prebot.log
:
2016-01-17 13:47:37 INFO log: started pynab logger
2016-01-17 13:47:38 INFO log: started pynab logger
2016-01-17 13:47:38 INFO Pre: Bot Nick - boo1234
2016-01-17 13:47:45 INFO pre: Inserted/Updated - NCIS.New.Orleans.S02E03.Der.Sonne.so.nah.GERMAN.DUBBED.WebHDRiP.x264-SOF
2016-01-17 13:48:49 DEBUG pre: Error parsing nzedbirc - 'NoneType' object has no attribute 'groupdict'
2016-01-17 13:48:50 INFO log: started pynab logger
2016-01-17 13:48:51 INFO log: started pynab logger
2016-01-17 13:48:51 INFO Pre: Bot Nick - boo1234
2016-01-17 13:48:58 INFO pre: Inserted/Updated - Lloyd_Robinson-Cuss_Cuss-(Promo_CDS)-2015-YVP_INT
2016-01-17 13:49:02 INFO pre: Inserted/Updated - Ptaki-Odglosy_Lasu-WEB-2013-I_KnoW_INT
2016-01-17 13:50:05 DEBUG pre: Error parsing nzedbirc - 'NoneType' object has no attribute 'groupdict'
2016-01-17 13:50:06 INFO log: started pynab logger
2016-01-17 13:50:08 INFO log: started pynab logger
2016-01-17 13:50:09 INFO Pre: Bot Nick - boo1234
Note the Error parsing nzedbirc - 'NoneType' object has no attribute 'groupdict'
lines.
brookesy2 commented
Lemme take a look. I should probably add better checking before I try use the dict :)