-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Fix for issue 3481 #3486
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
Fix for issue 3481 #3486
Conversation
Ok, I finally had a chance to look. I am pretty torn here... I think semantically this is wrong, as Unfortunately I cannot think of a straight-forward alternative; it seems necessary to add bit of new config/state in So I will have to think more about this. Apologies for slowness and thank you for your patience. |
No worries, @cowtowncoder. Thanks a lot for your feedback. I don't understand why The assumption of this fix is that If the users do not want to suppress the value in a particular way, the Actually, all the tests are passing when I run However, why there are two failing checks above? |
Original design started with This is not to say that the design could not change; all I am changing is that I am hesitant because quite often there are subtle reasons why certain things work in certain ways: I may be forgetting some detail here. But I agree that since only a small number of tests -- and in particular, ones that are quite specifically trying to drill into low level usage of these configuration settings -- fail, that's promising. |
I understand that there could be subtle reasons why things are done as they are. Can we say it's a safe change if all the tests are passing? How can I replicate the errors in the PR build locally? |
We can say whatever we want; the question is whether tests actually cover use cases that exist outside test suite. Now: there is something really weird going on with Github actions: errors seen there are bogus. I don't know when they started happening, or what might be causing them. It's... odd. And did not happen until very recently. Running |
I would suggest acting based on what we know, which is the test results. Definitely, there are always cases that we do not know. Yes, |
Hi @cowtowncoder, I was thinking about the possible impacts of this change as in the cases below.
If so, the consequence of the third case is not harmful and easy to fix. Please correct me if I'm wrong. |
Hi @AmiDavidW! Sorry for the slow responses again. I think I am actually ok with the minor possibility of regression and we can go ahead. But one last thing: this has to be against 2.14 branch just so we can get proper testing; I don't want this to go in 2.13 patch. Could you rebase it, and I can merge it, assuming unit tests pass? (I think I figure out a small tweak to CI to avoid those odd transient problems). |
URL: FasterXML#3481 1. Check JsonInclude.Include.CUSTOM filter before serializing null values (BeanPropertyWriter). 2. Make JsonInclude.Include.CUSTOM and suppressNull independent (PropertyBuilder). 3. Adapt the unit tests (JsonIncludeCustomTest).
367cdc1
to
b228cc8
Compare
Thank you very much @cowtowncoder! I rebased on 2.14 and the |
Merged for inclusion in 2.14.0. Thank you @AmiDavidW for your patience here in getting this done. :) |
Great :-) Thank you very much @cowtowncoder! The explanation and discussion are very interesting and helpful. I really appreciate it. |
URL: #3481
(BeanPropertyWriter).
(PropertyBuilder).