Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

!week & !termdates commands do not cope well when no data is set #140

Open
LordAro opened this issue Nov 6, 2018 · 1 comment
Open

!week & !termdates commands do not cope well when no data is set #140

LordAro opened this issue Nov 6, 2018 · 1 comment
Labels

Comments

@LordAro
Copy link
Member

LordAro commented Nov 6, 2018

Alan can add exception data below

@alanbriolat
Copy link
Member

Nov 06 16:52:53 csyorkbot app/worker.1: [2018/11/06 16:52:53] (D:csbot.raw_log) >>> ':[email protected] PRIVMSG #hacksoc :!week' 
Nov 06 16:52:53 csyorkbot app/worker.1: [2018/11/06 16:52:53] (I:csbot.pretty_log) [#hacksoc] <hackbot> !week 
Nov 06 16:52:53 csyorkbot app/worker.1: [2018/11/06 16:52:53] (I:csbot.pretty_log) Command ('week', '') fired by hackbot in channel #hacksoc 
Nov 06 16:52:53 csyorkbot app/worker.1: [2018/11/06 16:52:53] (E:asyncio) Unhandled exception in event task 
Nov 06 16:52:53 csyorkbot app/worker.1: future: <Task finished coro=<Bot.fire_command() done, defined at /app/csbot/core.py:160> exception=KeyError(None,)> 
Nov 06 16:52:53 csyorkbot app/worker.1: Traceback (most recent call last): 
Nov 06 16:52:53 csyorkbot app/worker.1:   File "/app/csbot/core.py", line 172, in fire_command 
Nov 06 16:52:53 csyorkbot app/worker.1:     yield from f(event) 
Nov 06 16:52:53 csyorkbot app/worker.1:   File "/app/.heroku/python/lib/python3.6/asyncio/coroutines.py", line 212, in coro 
Nov 06 16:52:53 csyorkbot app/worker.1:     res = func(*args, **kw) 
Nov 06 16:52:53 csyorkbot app/worker.1:   File "/app/csbot/plugins/termdates.py", line 85, in week 
Nov 06 16:52:53 csyorkbot app/worker.1:     term, weeknum = self._current_week() 
Nov 06 16:52:53 csyorkbot app/worker.1:   File "/app/csbot/plugins/termdates.py", line 138, in _current_week 
Nov 06 16:52:53 csyorkbot app/worker.1:     start, _ = self.terms[term] 
Nov 06 16:52:53 csyorkbot app/worker.1: KeyError: None 

@alanbriolat alanbriolat added the bug label Feb 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants