oddluck / limnoria-plugins

Limnoria plugins I wrote or forked.
Do What The F*ck You Want To Public License
39 stars 17 forks source link

Duckhunt longest times doesn't update #44

Open MetaNova opened 2 years ago

MetaNova commented 2 years ago
[2021.10.12-16.24.04] <@chat> Longest time: MetaNova with 63481.87 seconds (this is your new longest time
in this channel! Your previous longest time was 5.51)
[2021.10.12-16.47.02] <@chat> Longest time: MetaNova with 134.22 seconds (this is your new longest time
in this channel! Your previous longest time was 5.51)

Also:

<mornfall> +listtimes
<@chat> \_o< ~ DuckHunt top-5 fastest times for ##chat ~ >o_/
<@chat> (xicedjava37x: 1.04) (xwoodyj21x: 1.06) (xtallguyx: 1.1) (xshadow255x: 1.2) (x^-^hix: 1.33)
<@chat> \_o< ~ DuckHunt top-5 longest times for ##chat ~ >o_/
<@chat> (xbeefpotatox: 1 day, 12:11:30) (xHalianx: 6:34:47) (xrndusrx: 0:50:34) (xoxekx: 0:29:45) (xLooCfurx: 0:25:41)
<MetaNova> +rmtime beefpotato
<@chat> An error has occurred and has been logged. Check the logs for more information.
INFO 2021-10-13T12:44:04 rmtime called on ##chat by "MetaNova!zero-one@znc/supporter/metanova".
ERROR 2021-10-13T12:44:04 Uncaught exception in ['rmtime'].
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/dist-packages/supybot/callbacks.py", line 1583, in _callCommand
    self.callCommand(command, irc, msg, *args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/supybot/utils/python.py", line 91, in g
    f(self, *args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/supybot/callbacks.py", line 1549, in callCommand
    method(irc, msg, *args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/supybot/commands.py", line 1142, in newf
    f(self, irc, msg, args, *state.args, **state.kwargs)
  File "/home/ircbot/Limnoria/plugins/DuckHunt/plugin.py", line 606, in rmtime
    del self.channeltimes[channel][nick]
KeyError: 'beefpotato'
ERROR 2021-10-13T12:44:04 Exception id: 0xcfb91
MetaNova commented 1 year ago

I have resorted to simply deleting the DuckHunt_##chat.worsttimes file to reset the table from time to time. It will become populated, and, for a while, get updated accordingly.

Specs:

The current (running) version of this Limnoria is 2022.12.28, running on Python 3.10.9
(main, Dec  7 2022, 13:47:07) [GCC 12.2.0].  The newest versions available online are
2022.11.10 (in master), 2022.12.28 (in testing).

Latest git master of limnoria-plugins