Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork5.3k
Update Callback.rst#4161
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
Update Callback.rst#4161
Uh oh!
There was an error while loading.Please reload this page.
Conversation
"Symfony\Component\Validator\ExecutionContextInterface" namespace is deprecated, new namespace should be "Symfony\Component\Validator\Context\ExecutionContextInterface"
stof commentedAug 22, 2014
If you typehint the new interface instead of its deprecated parent, you make your bundle incompatible with the 2.4 API. So there should at least be a note sayign that any shared bundle should typehint the interface compatible with all versions of the API. Doing such change is safe only when you control the API version to force it being 2.5 or 2.5-bc |
lashae commentedAug 22, 2014
@stof This page belongs to documentation of version 2.5 (v2.4 has a seperate documentation), so do you really think that it is necessary to explicitly mention the issue you talk about? |
stof commentedAug 22, 2014
weaverryan commentedAug 25, 2014
My vote is to use the non-deprecated class, and then add (which we've talked about before but haven't done yet) a cookbook entry for third-party bundle authors about doing some extra things to keep compatibility. The multiple API's is kind of a pain in the butt, so I want to hide that pain from the end user (at the expense of the more-advanced OS bundle authors). |
lashae commentedAug 26, 2014
I agree with@weaverryan, deprecation period should also give us the chance to update the docs. |
weaverryan commentedSep 16, 2014
…, weaverryan)This PR was merged into the 2.5 branch.Discussion----------2.5 Validation API changes| Q | A| ------------- | ---| Doc fix? | no| New docs? | yes| Applies to | 2.5| Fixed tickets |#4094Hi guys!This takes the work in#4056,#4105 and#4161 and extends it based on some feedback. Basically, the whole validation stuff is quite difficult, because:A) We want to show the non-deprecated methods so people use the new stuffB) We don't want to confuse users on the 2.4 API (even though this number of users should be very small, as it would require you to have started a project in the past and be using 5.3.9 and lower#4105 (comment))This solution is to show the new way, but always show the old way in comments. This would check of A and B in#4094.Thanks!Commits-------9874d8e [#4233][#4094] Making validateValue and validate changes94fc520 Minor tweaks and a missing location thanks to xabbuh and WouterJf97ba7a Fixes thanks to@xabbuh279d8d6 Adding a section about keeping BC in a re-usable bundle280440e Adding details about the 2.4 API as commentse658b56 added a versionadded comment to Callback.rst70c5ca1 Update custom_contraint.rst to meet the new 2.5 api5dfe499 Don't use deprecated functions in Callback.rstf4380ed Update Callback.rst042dcf9 Replace addViolationAt (deprecated) by buildViolation
"Symfony\Component\Validator\ExecutionContextInterface" namespace is deprecated, new namespace should be "Symfony\Component\Validator\Context\ExecutionContextInterface"