You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm processing some JSON files that I got from an external source. Everything was going well until I hit this on one of them:
Caused by: jakarta.json.stream.JsonParsingException: Unexpected char 65,279 at (line no=1, column no=1, offset=0)
at org.eclipse.parsson.JsonTokenizer.unexpectedChar (JsonTokenizer.java:584)
at org.eclipse.parsson.JsonTokenizer.nextToken (JsonTokenizer.java:396)
at org.eclipse.parsson.JsonParserImpl$NoneContext.getNextEvent (JsonParserImpl.java:425)
at org.eclipse.parsson.JsonParserImpl.next (JsonParserImpl.java:375)
at org.eclipse.parsson.JsonReaderImpl.readObject (JsonReaderImpl.java:99)
It looks like the file has a BOM char at its start.
I'm pretty sure (but not positive) that isn't allowed, but I'm wondering if the Parsson authors are interested in making the parser resilient to this situation.
Implementations MUST NOT add a byte order mark (U+FEFF) to the
beginning of a networked-transmitted JSON text. In the interests of
interoperability, implementations that parse JSON texts MAY ignore
the presence of a byte order mark rather than treating it as an
error.
The text was updated successfully, but these errors were encountered:
I'm processing some JSON files that I got from an external source. Everything was going well until I hit this on one of them:
It looks like the file has a BOM char at its start.
I'm pretty sure (but not positive) that isn't allowed, but I'm wondering if the Parsson authors are interested in making the parser resilient to this situation.
From https://datatracker.ietf.org/doc/html/rfc8259#section-8.1
The text was updated successfully, but these errors were encountered: