Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.6k
[Config] Improve the deprecation features by handling package and version#35871
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
[Config] Improve the deprecation features by handling package and version#35871
Uh oh!
There was an error while loading.Please reload this page.
Conversation
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.
We still need to keep some tests (marked as@group legacy
) covering the old API. Otherwise our BC layer is untested.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
src/Symfony/Component/Config/Definition/Builder/VariableNodeDefinition.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
97deb48
to6f80928
Compare603caa7
to0c829a3
CompareUh oh!
There was an error while loading.Please reload this page.
0c829a3
to5999461
Compare5999461
to9ebe1a3
CompareThere 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.
(with minor comments)
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
src/Symfony/Component/Config/Definition/Builder/NodeDefinition.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
src/Symfony/Component/Config/Definition/Builder/NodeDefinition.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
99705c1
tobb1e5bc
CompareUh 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.
src/Symfony/Component/Config/Definition/Builder/NodeDefinition.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
0fa3233
toc8ddd80
Comparesrc/Symfony/Component/Config/Tests/Definition/Builder/ArrayNodeDefinitionTest.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
@atailouloute can you please take my comment into account and rebase meanwhile? |
c8ddd80
tobc42f71
Compare@nicolas-grekas Done |
bc42f71
tof4de76d
CompareThank you@atailouloute. |
* You can use %node% and %path% placeholders in your message to display, | ||
* respectively, the node name and its complete path. | ||
*/ | ||
public function setDeprecated(?string $message) | ||
public function setDeprecated(?string $package/*, string $version, string $message = 'The child node "%node%" at path "%path%" is deprecated.' */) |
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.
Adding the parameters at the front makes it impossible to both support 5.1+ and <5.1 as a bundle.
If you use the intended 5.1+ way:->setDeprecated("my/bundle", "1.0", "this node is deprecated, do sth else")
- in
5.1+
we will show the message"this node is deprecated, do sth else"
- in
<5.1
we will show the message"my/bundle"
Is there a (non-hacky) way to have the real message in both versions?
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 just created#37284 to track this
Uh oh!
There was an error while loading.Please reload this page.