-
Notifications
You must be signed in to change notification settings - Fork 1.1k
NewtonSoftJsonSerializer
throws a StackOverflow
exception when trying to deserialize an object
field
#6502
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
Comments
We'll release a fix for this in 1.4.50 and 1.5.1 |
Is there any relation to these types of issues? #4463 i.e. is this all Newtonsoft.Json type-conversion issues? |
That issue is actually by design, we are replacing int, decimal, and float with a JObject so that we can preserve the value type inside an anonymous object across the wire. |
Note that we're not replacing long and double as those are actually the default Newtonsoft Json behavior |
Which issue? |
I was replying to your comment on issue #4463 |
Ah ok, so close that then? |
Either close that issue, or reconsider our JSON wire format to not replace value types |
Done |
These are the corresponding lines: akka.net/src/core/Akka/Serialization/NewtonSoftJsonSerializer.cs Lines 432 to 438 in f92c609
akka.net/src/core/Akka/Serialization/NewtonSoftJsonSerializer.cs Lines 455 to 464 in f92c609
|
…o deserialize a `JObject` inside an `object` field (#6503) * Reproduction for #6502 * Fix JObject inside object property/field overflow --------- Co-authored-by: Aaron Stannard <[email protected]>
…o deserialize a `JObject` inside an `object` field (akkadotnet#6503) * Reproduction for akkadotnet#6502 * Fix JObject inside object property/field overflow --------- Co-authored-by: Aaron Stannard <[email protected]> (cherry picked from commit 64c6eff)
…rializer` tries to deserialize a `JObject` inside an `object` field (#6522) * Fix `StackOverflow` exception when `NewtonsoftJsonSerializer` tries to deserialize a `JObject` inside an `object` field (#6503) * Reproduction for #6502 * Fix JObject inside object property/field overflow --------- Co-authored-by: Aaron Stannard <[email protected]> (cherry picked from commit 64c6eff) * Remove nullable support
Version Information
Version of Akka.NET? 1.4.49/1.5.0
Which Akka.NET Modules? Akka
Describe the bug
NewtonSoftJsonSerializer
throws aStackOverflow
exception when trying to deserialize a class with anobject
field/property when assingned aJObject
instance.To Reproduce
Steps to reproduce the behavior:
#6503
Expected behavior
Should deserialize successfully
Actual behavior
Throws
StackOverflow
Environment
Any
The text was updated successfully, but these errors were encountered: