Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
[Validator] Add BC layer for notInRangeMessage when min and max are set#36140
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
Uh oh!
There was an error while loading.Please reload this page.
Conversation
dmaicher commentedMar 19, 2020
Also see#33700 I also noticed that and back then we decided to document this small behavior change. |
2d50ed1 tof12794eCompareUh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
d8f0c3f to1136014Comparechalasr commentedMar 19, 2020
Adding a BC layer on a maintenance branch feels wrong to me, you shouldn't get new deprecation notices in a patch release. The BC break should either be reverted or documented instead. |
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
1136014 todc9a366Comparedc9a366 to092d85cComparenicolas-grekas commentedMar 31, 2020
Reverting would mean breaking BC on 5.0 - Documenting is what this PR is about. Note that I didn't get the patch so I'm just commenting on the process :) |
Uh oh!
There was an error while loading.Please reload this page.
fabpot commentedAug 12, 2020
@l-vo What's the status here? |
l-vo commentedAug 12, 2020
@fabpot from my point of view the fix itself is finished, the blocking point is more a discussion between contributors/core members about what should be done here. |
fabpot commentedAug 12, 2020
Thank you@l-vo. |
fabpot commentedAug 12, 2020
@l-vo I've merge 4.4 into 5.1, can you create a PR for 5.1 where you remove the BC layer? |
l-vo commentedAug 12, 2020
Of course, I'm AFAK today but I'm doing it tomorrow. |
This PR was merged into the 4.4 branch.Discussion----------[Validator] RangeTest: fix expected deprecation| Q | A| ------------- | ---| Branch? | 4.4| Bug fix? | no| New feature? | no <!-- please update src/**/CHANGELOG.md files -->| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->| Tickets |#36140 <!-- prefix each issue number with "Fix #", no need to create an issue if none exist, explain below instead -->| License | MIT| Doc PR | N/AFixeshttps://travis-ci.org/github/symfony/symfony/jobs/717184009#L5830-L5831Commits-------33c8c3a [Validator] RangeTest: fix expected deprecation
l-vo commentedAug 12, 2020
@fabpot Do we really want to remove the BC layer in 5.x ? In the early 5.0 and 5.1 versions, the behavior of |
fabpot commentedAug 13, 2020
@l-vo Right, let's remove it for 6.0. |
According to#36133, the improvement added in#32435 may lead to a BC break when the developer pass
minandmaxoptions and a customminMessageormaxMessage. In this case it's expected to receive aminMessage/maxMessagein the violation but anotInRangeMessageis received instead.So in the following conditions:
minandmaxoptions are setminMessageormaxMessageis setA deprecation is triggered. If a limit is violated and matches to the min/max message passed as option (
minMessageforminviolated andmaxMessageformaxviolated),minMessage/maxMessageis used in the violation instead ofnotInRangeMessage.