jackson-dataformat-xml icon indicating copy to clipboard operation
jackson-dataformat-xml copied to clipboard

Coercion of `null` Strings to "" incorrect for 3.0

Open cowtowncoder opened this issue 6 years ago • 5 comments

With rewrite of XML module for 3.0, something is wrong with coercion if null values -- so after #354 resolved this for 2.x, there is now one unit test that only fails for 3.0. This is due to combination of null->Empty coercion in XmlMapper, line ~85:

            _configOverrides.findOrCreateOverride(String.class)
                .setNullHandling(JsonSetter.Value.forValueNulls(Nulls.AS_EMPTY));

but removing that line will fail a bunch of other tests that do expect empty String from input to be taken as empty String, not null.

cowtowncoder avatar Sep 08 '19 17:09 cowtowncoder

Was fixed.

cowtowncoder avatar Jun 30 '20 04:06 cowtowncoder

No, not fixed; test was simply moved under failing. Re-opening.

cowtowncoder avatar Nov 13 '20 22:11 cowtowncoder

What is the status of this issue?

mensinda avatar May 03 '22 13:05 mensinda

@mensinda If there are no updates on the issue, typically nothing has happened. Note that the issue for upcoming (future) Jackson 3.x, not currently released 2.x versions.

cowtowncoder avatar May 04 '22 18:05 cowtowncoder

@cowtowncoder Oh, sorry for the noise. I did not check this manually and did not notice the major version bump...

mensinda avatar May 05 '22 11:05 mensinda