Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
[Serializer] Deprecate support for abstract uid denormalization in UidNormalizer#44721
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
[Serializer] Deprecate support for abstract uid denormalization in UidNormalizer#44721
Uh oh!
There was an error while loading.Please reload this page.
Conversation
cffe3b8 to09000e1Comparesrc/Symfony/Component/Serializer/Tests/Normalizer/UidNormalizerTest.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
nicolas-grekas commentedDec 25, 2021
(rebase needed) |
09000e1 to8661042CompareUh oh!
There was an error while loading.Please reload this page.
38431ca to4075944Compare4075944 tob0c07f8Compare| * Deprecate supporting denormalization for`AbstractUid` in`UidNormalizer`, use one of`AbstractUid` child class instead | ||
| * Deprecate denormalizing to an abstract class in`UidNormalizer` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
to me this signals the same deprecation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
There is one deprecation forsupportsDenormalization() that will return false instead of true forAbstractUid::class specifically.
And another fordenormalize() that will throw an\Error if the class is abstract (instead of fallbacking toUuid::class).
nicolas-grekas left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
rebase needed
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
793a7b2 to6ed7a68Compare6ed7a68 to6fc4287Comparenicolas-grekas commentedFeb 23, 2022
Thank you@fancyweb. |
…(fancyweb)This PR was merged into the 7.0 branch.Discussion----------[Serializer] Remove abstract uid denormalization code| Q | A| ------------- | ---| Branch? | 7.0| Bug fix? | no| New feature? | yes| Deprecations? | no| Tickets | -| License | MIT| Doc PR | -Removes the code that was deprecated in#44721Commits-------79028f9 [Serializer] Remove abstract uid denormalization code
Continuation of#44600. All abstract classes should not be denormalized to Uuid::class. We need a concrete class. Instead of penalizing everyone with reflection in supportsDenormalization(), let's just bubble up the PHP \Error (we are going to do the same in UidValueResolver).