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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Form] Deprecate not configuring the default_protocol
option of the UrlType
#50922
Conversation
IIRC we overrode the tests in other cases. But we should add a comment that the overridden methods can be removed in the |
Thanks @xabbuh, hope I did it correctly |
src/Symfony/Component/Form/Tests/Extension/Core/Type/UrlTypeTest.php
Outdated
Show resolved
Hide resolved
cb28233
to
a2eac76
Compare
a2eac76
to
81a5079
Compare
81a5079
to
77802f8
Compare
Is it still time to merge this in 6.4 or will I have to rebase on 7.1 when the branch will be created? |
we should have a test ensuring that passing |
src/Symfony/Component/Form/Tests/Extension/Core/Type/UrlTypeTest.php
Outdated
Show resolved
Hide resolved
src/Symfony/Component/Form/Tests/Extension/Core/Type/UrlTypeTest.php
Outdated
Show resolved
Hide resolved
@stof thanks for the review 🙏 Do you know how I can test whether a given code does not trigger a deprecation? |
@MatTheCat Don't put the |
You should add a test that runs into the situation, and if it triggers a deprecation, the CI will fail. |
src/Symfony/Component/Form/Tests/Extension/Core/Type/UrlTypeTest.php
Outdated
Show resolved
Hide resolved
src/Symfony/Component/Form/Tests/Extension/Validator/Type/UrlTypeValidatorExtensionTest.php
Outdated
Show resolved
Hide resolved
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.
I think this can wait for 7.1
16bcc43
to
286bab1
Compare
286bab1
to
3ce498d
Compare
Thank you @MatTheCat. |
You would expect an
<input type="url">
from theUrlType
, but it is not possible as long asdefault_protocol
has a value, because then you have to accept inputs that are not URLs (and you get an<input type="text" inputmode="url">
).In order to change
default_protocol
from'http'
tonull
in 8.0, we must first deprecate not configuring it.