dferrante / pywx

python weather bot
10 stars 3 forks source link

Locate command produces error #7

Closed dziban303 closed 7 years ago

dziban303 commented 7 years ago

Upon running the locate command, this is output in the console:

2017-08-29 01:24:48,880 DEBUG :dziban303!dziban303@user/dziban303 PRIVMSG #dzibania :locate 2017-08-29 01:24:48,881 INFO got command locate {'ident': ':dziban303!dziban303', 'command': 'locate', 'sender': 'dziban303', 'msg': 'locate', 'chan': '#dzibania', 'args': '', 'mask': 'user/dziban303', 'bot': <pythabot.Pythabot instance at 0x7f8670487950>} 2017-08-29 01:24:48,887 ERROR super(type, obj): obj must be an instance or subtype of type Traceback (most recent call last): File "/mnt/e/wxbot/dziwx/pywx/modules/base.py", line 88, in run context = self.context(msg) File "/mnt/e/wxbot/dziwx/pywx/modules/weather.py", line 416, in context payload = super(Locate, self).context(msg) TypeError: super(type, obj): obj must be an instance or subtype of type

I created a fresh git clone and it throws the same error.

It's got something to do with the eclipse command code in weather.py. When the eclipse command is removed or commented out, locate works again.

The order matters, too. If the eclipse code block is cut & pasted above the locate code, the locate command works again while the eclipse command throws the same error as above.

dziban303 commented 7 years ago

duplicate class name. fixed