-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Update framework.exceptions
XML and PHP configuration examples
#17455
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
Conversation
a540745
to
6527016
Compare
6527016
to
246b741
Compare
framework.exceptions
XML and PHP configuration examplesframework.exceptions
XML and PHP configuration examples
… with a config builder (MatTheCat) This PR was squashed before being merged into the 5.4 branch. Discussion ---------- [FrameworkBundle] Allow configuring `framework.exceptions` with a config builder | Q | A | ------------- | --- | Branch? | 5.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | Fix #48191 | License | MIT | Doc PR | symfony/symfony-docs#17455 It seems the `framework.exceptions` definition has been wrongly configured for XML. As a result it is not possible to set its value using a config builder. This pull request adds a “right” way to configure `framework.exceptions` using XML. The old one should be deprecated for `6.3` and removed for `7.0`. [The documentation](https://symfony.com/doc/current/reference/configuration/framework.html#exceptions) is also wrong and should be fixed (ideally after this pull request is merged). Guidance is requested to add a test (current failures unrelated) 🙏 Commits ------- 57e28f6 [FrameworkBundle] Allow configuring `framework.exceptions` with a config builder
… with a config builder (MatTheCat) This PR was squashed before being merged into the 5.4 branch. Discussion ---------- 8000 [FrameworkBundle] Allow configuring `framework.exceptions` with a config builder | Q | A | ------------- | --- | Branch? | 5.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | Fix #48191 | License | MIT | Doc PR | symfony/symfony-docs#17455 It seems the `framework.exceptions` definition has been wrongly configured for XML. As a result it is not possible to set its value using a config builder. This pull request adds a “right” way to configure `framework.exceptions` using XML. The old one should be deprecated for `6.3` and removed for `7.0`. [The documentation](https://symfony.com/doc/current/reference/configuration/framework.html#exceptions) is also wrong and should be fixed (ideally after this pull request is merged). Guidance is requested to add a test (current failures unrelated) 🙏 Commits ------- 57e28f6bda [FrameworkBundle] Allow configuring `framework.exceptions` with a config builder
->status_code(422); | ||
$framework->exception(BadRequestHttpException::class) | ||
->logLevel('debug') | ||
->statusCode(422) | ||
; | ||
}; | ||
|
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.
Deprecated directive for version 6.3 is missing. Can you add it?
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.
Is that really necessary since the deprecated format was never documented?
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 agree, it is not necessary
Thanks Mathieu. |
… with a config builder (MatTheCat) This PR was squashed before being merged into the 5.4 branch. Discussion ---------- [FrameworkBundle] Allow configuring `framework.exceptions` with a config builder | Q | A | ------------- | --- | Branch? | 5.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | Fix #48191 | License | MIT | Doc PR | symfony/symfony-docs#17455 It seems the `framework.exceptions` definition has been wrongly configured for XML. As a result it is not possible to set its value using a config builder. This pull request adds a “right” way to configure `framework.exceptions` using XML. The old one should be deprecated for `6.3` and removed for `7.0`. [The documentation](https://symfony.com/doc/current/reference/configuration/framework.html#exceptions) is also wrong and should be fixed (ideally after this pull request is merged). Guidance is requested to add a test (current failures unrelated) 🙏 Commits ------- 57e28f6bda [FrameworkBundle] Allow configuring `framework.exceptions` with a config builder
symfony/symfony#48259 doc PR
Fix #17609