mapbox/tilesets-cli

`validate-recipe` returns bad output on Malformed JSON

Closed this issue · 1 comments

I had a missing comma in my recipe that led to this error message.

Screen Shot 2020-07-08 at 5 29 09 PM

The output of invalid JSON from the validate-recipe command returns a pretty confusing stacktrace instead of invalidating the missing comma in my recipe

This is a fairly standard python error, and the output does give the necessary information (Expecting ',' delimiter...) -- I don't think other ways of raising this error are likely to have a friendlier stack trace.

We can consider other ways of communicating error output to the user that don't involve raising errors, or minimizing the stack trace we convey to the user, but this would be a change from our current error handling patterns.