brockfanning / jekyll-get-json

Import remote JSON data into the data for a Jekyll site
MIT License
72 stars 17 forks source link

Error loading JSON should abort site build #6

Open davidc opened 4 years ago

davidc commented 4 years ago

At the moment if there's an error loading the JSON (e.g. 404), there is no error printed, and the site build continues as if nothing had gone wrong. It should abort so that whatever is building the site doesn't then deploy a broken site.

brockfanning commented 4 years ago

This sounds reasonable to me. I wonder if that behavior should be optional, since it may cause some existing projects to begin failing. Or, should we just make the change - probably as part of a minor (or major?) version bump?

davidc commented 4 years ago

I'm not sure I can imagine a scenario where someone would want to proceed and build a broken site rather than abort, but yes a version bump would be reasonable!

If someone does come up with a use case for that, a new "ignore_load_errors" type key in the yaml could be added to let it continue.