Fix JSON dangling commas, and make parser ignore unparseable files