visidata icon indicating copy to clipboard operation
visidata copied to clipboard

[sheet-] in execCommand(), fail if cmd does not exist

Open midichef opened this issue 5 days ago • 0 comments

A command that does not exist, like qqquit-sheet, will be skipped during replay of a macro or command log, but the subsequent commands will continue to be replayed.

Some ways that could happen: a user makes a typo editing a command name in a macro or command log. Or in the past, the user defined a command to be used in a macro, for example, loggable-quit-sheet, and now they delete the command definition, breaking the macro that uses it.

It seems better to fail() instead of warning() in this case. Is there a case where warning() is better?

midichef avatar Jun 30 '24 06:06 midichef