-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Qute calls accessor method instead of using property for boolean (since 1.12.0.Final) #15334
Comments
/cc @mkouba |
Hm, this is a regression caused by a fix for #14918. After the fix we always use the generated getters to access properties of a Panache entity. However, it seems that the generated getters @JsonProperty
public Boolean getCompleted() {
return this.$$_hibernate_read_completed();
} UPDATE: I need to correct myself - it does follow the naming conventions, but in this case we have @FroMage would it be possible to use |
Tried to use
|
Yeah, that's expected because we don't see the generated methods during validation. Nevermind, I'll try to solve the problem on the Qute side -> we'll use |
When I try to add the method manually (tried both
|
How does the expression look like? It looks like an elvis operator is used? Note that there was a regression in primitive types validation fixed in #15161 (to be included in 1.12.1). In any case, I have a fix and once I have a proper test I'll send a PR. |
Yes this is in a ternary:
When i change the getter to object it works - so it is #15161
Thx for the quick reaction!!! |
- resolves quarkusio#15334 (cherry picked from commit 681fb4b)
Describe the bug
When referencing a boolean property value Qute now calls the
isXxx()
method instead of referencing the property directly.Example entity:
Example template:
Expected behavior
Panache entities have public properties - this should be used when there is no bean accessor method.
Actual behavior
The following exception occurs:
To Reproduce
Here is a sample project to reproduce this: https://github.com/derkoe/quarkus-htmx-todos/
Steps to reproduce the behavior:
Environment (please complete the following information):
java -version
:mvnw --version
orgradlew --version
):Additional context
This problem does not occur with Quarkus 1.11.3.Final
The text was updated successfully, but these errors were encountered: