Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
[FrameworkBundle] deprecate not setting http_method_override#45989
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
[FrameworkBundle] deprecate not setting http_method_override#45989
Uh oh!
There was an error while loading.Please reload this page.
Conversation
| ->children() | ||
| ->scalarNode('secret')->end() | ||
| ->scalarNode('http_method_override') | ||
| ->booleanNode('http_method_override') |
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.
The only boolean node that wasn't defined as such and missed validation.
| ->booleanNode('http_method_override') | ||
| ->info("Set true to enable support for the '_method' request parameter to determine the intended HTTP method on POST requests. Note: When using the HttpCache, you need to call the method in your front controller instead") | ||
| ->defaultTrue() | ||
| ->treatNullLike(false) |
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.
currently setting it to null caused a type error in the FrameworkExtension which is now fixed. making it a boolean node still permits null. so this also ensures that null is transformed to false (instead of true which is the default in boolean node)
nicolas-grekas left a comment• edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
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.
LGTM. Please add CHANGELOG+UPGRADE entries
Tobion commentedApr 13, 2022
@nicolas-grekas I need to adapt tests don't I? The option needs to be set in alot of functional tests. |
nicolas-grekas commentedApr 13, 2022
yes indeed |
Tobion commentedApr 19, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
@nicolas-grekas is there a way to ignore this deprecation notice in Symfony tests when it's self triggered. otherwise I have to explicitly set the http_method_override: false in hundrets of test fixtures. kinda ugly and pointless. |
nicolas-grekas commentedApr 19, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Nope there's none, and that's on purpose to me: eat our own dog food. We're asking ppl to opt-in, including ourselves. |
Tobion commentedApr 19, 2022
Well, users will not be affected when using the recipes. And the people who are, only need to change 1 line. We have to adjust hundrets of unrelated tests. |
8b29d0d to9be468fComparee1df1f7 toa156313CompareTobion commentedApr 20, 2022
I fixed the tests and adding changelog/upgrade. This is ready now. |
a156313 tof9cf24aComparefabpot commentedApr 21, 2022
Thank you@Tobion. |
Uh oh!
There was an error while loading.Please reload this page.
In preparation for changing the default in 7.0.