JSON decode error - float values [message #1853290] |
Sun, 26 June 2022 15:14  |
Eclipse User |
|
|
|
Hello,
I am receiving a JSON message from a component, which I decode with the internal JSON decoder.
From time to time I get decoding errors from the internal JSON decoder.
While JSON-decoding type ...: Failed to extract valid token, invalid JSON format
Can not decode type ..., because invalid or incomplete message was received
It seems that it is related to float values in certain ranges. I typically receive rather small values in exponential format, e.g. 2.7e-9.
I can reproduce this behavior in the attached minimal example where different JSON messages with float values are sent, where some can be decoded and others not.
Is there an explanation for this behavior?
Best regards,
Fabian
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04499 seconds