Some `_exec` optimizations

It may be more helpful when debugging to have specific messages for each of these instead of one generic message, e.g. `"Command must be a string"` or `"Expected parameters as a string"`.