Repository navigation
Reject a getter which requires a parameter when extracting by value - #315
Merged
TomHAnderson merged 1 commit intoOct 3, 2026
Merged
Conversation
The hydrator calls the getter of every mapped field and association,
exposed or not, without arguments. The getter check accepted a getter
which requires a parameter, so every query of the entity's type failed,
even one which did not ask for the field, as an Internal server error
("Too few arguments").
Building the type now throws Exception\Hydrator naming the field and its
getter. The check covers every mapped field and association, and an
entity's __call no longer skips it, as explicit getters are still
called. A getter whose parameters are optional is called without them.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## 14.0.x #315 +/- ##
===========================================
Coverage 100.00% 100.00%
- Complexity 1195 1199 +4
===========================================
Files 80 80
Lines 3227 3240 +13
===========================================
+ Hits 3227 3240 +13 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The hydrator calls the getter of every mapped field and association, exposed or not, without arguments. The getter check accepted a getter which requires a parameter, so every query of the entity's type failed, even one which did not ask for the field, as an Internal server error ("Too few arguments").
Building the type now throws Exception\Hydrator naming the field and its getter. The check covers every mapped field and association, and an entity's __call no longer skips it, as explicit getters are still called. A getter whose parameters are optional is called without them.