-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
BeanDeserializer
updates currentValue
incorrectly when deserialising empty Object
#4184
Comments
There is still no reproduction yet, makes no difference from original #1834 labeld as "need-test-case"🤔. You may refer to issues that are labeled as "has-failing-test" for reproductions are provided --the reproduction would be complete, but minimal. |
Still need reproduction, no work will be done without one. As @JooHyukKim suggested, verbal description is not reproduction. But one thing to note is that deserializers do not need to reset anything: current value should be bound at correct level, so as long as they do not overwrite current values it should all work due to nesting (different read/write context levels have different current values). |
Reproduction:
|
One quick note:
will definitely parse content and likely change |
Ok. I forgot one aspect here: "current value" is specified for each nesting level, and so when deserializing and opening START_OBJECT (that is,
but with that, I can reproduce discrepancy between Empty Object and non-empty. I'll see if this can be fixed. |
BeanDeserializer
updates currentValue
incorrectly when deserialising empty Object
Found a way to resolve the issue, have simplified reproduction; fix will go in 2.16.0 -- no plans to backport in 2.15 or earlier. |
Thank you @nocny-x for reporting this and providing the reproduction! |
Originally posted by @cowtowncoder in #1834 (comment)
field2 has a deserializer and get the the context's current value in deserialize method, the context's current value is the value of field1.
Field2 Deserializer code snippet:
The text was updated successfully, but these errors were encountered: