Skip to content

Reproduce #5271 issue in 2.16#5276

Closed
JooHyukKim wants to merge 7 commits into
FasterXML:2.16from
JooHyukKim:reproduce-5271
Closed

Reproduce #5271 issue in 2.16#5276
JooHyukKim wants to merge 7 commits into
FasterXML:2.16from
JooHyukKim:reproduce-5271

Conversation

@JooHyukKim

@JooHyukKim JooHyukKim commented Aug 25, 2025

Copy link
Copy Markdown
Member

Reproduction for #5271

Comment on lines +30 to +32
_testConvert(JsonMapper.builder().disable(DeserializationFeature.READ_ENUMS_USING_TO_STRING)
.build()
);

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one would pass since DeserializationFeature.READ_ENUMS_USING_TO_STRING is default behavior.

@cowtowncoder

Copy link
Copy Markdown
Member

I am normally +1 for merging into older versions, but in this case problem is that due to Sonatype's switch from OSSRH to Central Repository, CI only works for branch 2.18 and later (where fixes were made).

So @JooHyukKim could you re-create this against 2.18?

@cowtowncoder

Copy link
Copy Markdown
Member

(tried close & re-open to re-trigger CI)

public void testJsonValueForEnumMapKey() throws Exception {
assertEquals(a2q("{'stuff':{'longValue':'foo'}}"),
MAPPER.writeValueAsString(new MyStuff594("foo")));
MyStuff594 ff = MAPPER.readValue(a2q("{'stuff':{'longValue':'foo'}}"), MyStuff594.class);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I merged this separately; fails in 3.0 as expected, passes on 2.18 - 2.20

@cowtowncoder

Copy link
Copy Markdown
Member

Re-created as #5282, closing this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants