-
Notifications
You must be signed in to change notification settings - Fork 105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fails to parse valid JSON #39
Comments
Why do you pass 16 as length instead of actual string length in utf8 bytes? You should be doing something along the lines of
|
btw. tnx for the bug report regarding StringIndexOutOfBoundsException. That's an unexpected exception which is now fixed. btw2. the reason why there is no deserialize(Class, String) API is to discourage use of String. But I guess I could provide helper method for input bytes without asking for length (although thats not much better than String - since it does not encourage reuse) |
Actually in my application I used the InputStream version and it failed the
same way as with the original/longer JSON.
…On Oct 4, 2017 08:19, "zapov" ***@***.***> wrote:
btw. tnx for the bug report regarding StringIndexOutOfBoundsException.
That's an unexpected exception which is now fixed.
btw2. the reason why there is no deserialize(Class, String) API is to
discourage use of String. But I guess I could provide helper method for
input bytes without asking for length
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#39 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAOKQvaAI8Hp0gAMfmm5TciKN0Hs8Es6ks5soxVMgaJpZM4Ps0Ds>
.
|
I'll prepare another test case. |
It appeared to be a small typo in the JSON that caused the original problem. |
I'm trying to parse JSON like:
But it fails with:
I've tried to simplify the JSON to find what exactly causes the problem to:
but now it fails with:
My Java code is :
The text was updated successfully, but these errors were encountered: