-
-
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
test for issue #4917 #4918
base: 2.19
Are you sure you want to change the base?
test for issue #4917 #4918
Conversation
could you please add: assertEquals(50, issue.number); ? |
@cowtowncoder this test case does reproduce the issue for the double. It gets the wrong value - it gets the value from the decimal field instead. So far, it seems like the issue was introduced in v2.15 - probably v2.15.0. Unfortunately 2.15.0 has a lot of changes and it would seem that one of changes to bring in the lazy evaluation of numbers is the cause of this issue. |
@cowtowncoder FasterXML/jackson-core#1389 seems to fix this |
@cowtowncoder FasterXML/jackson-core#1389 has a test where I reproduced the issue Maybe we could get 1389 and this merged to the 2.19 branches and backfit to jackson 2.18 and 2.17 (maybe 2.16)? The issue is not related to TokenBuffer and appears to be related to using getNumberType call on the parser and then not using a call to get the number - which leaves behind a non-nulled _numberString value. When the next number is an int (in the JSON), the code does not update the _numberString and maintains the _numberInt directly but some code paths can then go back to _numberString despite it being for an earlier number. |
test case for #4917