monome / crow

Crow speaks and listens and remembers bits of text. A scriptable USB-CV-II machine
GNU General Public License v3.0
166 stars 34 forks source link

Better error messaging in core libs #398

Closed trentgill closed 3 years ago

trentgill commented 3 years ago

After discussion around #395 it seems that error messaging is too minimal on crow. Indeed when I was trying to demonstrate the difference between stripped debug info, even the un-stripped version was pretty useless in tracking down a problem.

Basically there are a lot of conditionals in the core lib that fail silently or return nil when they should also inform the user that they provided incompatible data.

I think it would just take a quick pass going through all the core libs and adding a bunch of else cases for match-failures and showing errors with print 'XX was called incorrectly' as appropriate.

trentgill commented 3 years ago

closing this, not because it's a bad idea, but because i don't think we have flash space to do it meaningfully, and it's too abstract to be implemented directly.

happy to resurrect the conversation if someone wants to step in and propose a solution in future.