-
Notifications
You must be signed in to change notification settings - Fork 198
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
When retrieving data from DB Exception thrown with "Null value read for non-null constructor argument" message - after upgrading to Micronaut Parent 4.7.2 #3267
Comments
Looks like caused by micronaut-core 4.7.6 release @graemerocher and supposedly this PR micronaut-projects/micronaut-core#11347 |
Yeah, It works with micronaut.core.version 4.7.5 I have also tried with micronaut.core.version 4.7.9 to see if micronaut-projects/micronaut-core#11451 fixes it, but it does not |
It gets fixed by annotating title field as
So this may not be a bug but configuration issue. |
I did find that "workaround" and it "solves" it, but I don't think it is an elegant or reasonable solution. If I don't want a field to allow nulls I add And also it is a not documented regression. |
@graemerocher |
I don't think this is related to an upstream change. @radovanradic do you know if we added non-checking somewhere? |
I don't think there were changes in micronaut-data around this in this release where issue is reported. |
ok will investigate |
I sent a PR for this micronaut-projects/micronaut-core#11481 |
…f builder (#11481) Currently if there is a builder then it is preferred over the constructor. This is a regression from 4.6.x behaviour. This alters the behaviour to prefer the constructor if one is present when returning getConstructorArguments() Fixes micronaut-projects/micronaut-data#3267
@graemerocher @radovanradic I have released core 4.7.10. |
should probably add a downstream test in data once we upgrade |
Hi, |
Expected Behavior
@MappedEntity should be possible be created with null field values when retrieving data from DB.
Actual Behaviour
When retrieving data from DB Exception thrown with "Null value read for non-null constructor argument" message after upgrading to Micronaut Parent 4.7.2
Stack trace
See example at to reproduce the problem at https://github.com/balapal/micronaut-47-null-check-introduced
I downgrade to micronaut-parent 4.7.0, everything works again.
Steps To Reproduce
See the example app to reproduce this issue at https://github.com/balapal/micronaut-47-null-check-introduced
Environment Information
No response
Example Application
https://github.com/balapal/micronaut-47-null-check-introduced
Version
4.7.2
The text was updated successfully, but these errors were encountered: