signalbot icon indicating copy to clipboard operation
signalbot copied to clipboard

Improve error message if handle() method not implemented in Command.

Open brettp opened this issue 9 months ago • 1 comments

Small quality of life improvement that prevents an unhelpful error if you have a typo in the handle() method (and spent longer than you should have wondering what wasn't working).

Was: ERROR:root:[TestCommand] Error:

Now: ERROR:root:[TestCommand] Error: handle() method not implemented

brettp avatar May 12 '24 01:05 brettp

I updated this to improve the error logging for the other case also by adding the exception class.

Was:

ERROR:root:[TestCommand] Error: 'res'

Now:

ERROR:root:[TestCommand] <class 'KeyError'> Error: 'res'

brettp avatar May 12 '24 01:05 brettp