better json parsing diagnostics