wrap json parsing errors and switch to 1 based line numbering