-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
Log deprecations on a dedicated Monolog channel #36621
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
a62d9e2
to
9867d58
Compare
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!
I'm wondering: is there a way to make the new channel a kind of alias for the "php" one, so that deprecations follow the same path as the php logs by default?
Note: if this PR is merged, it'll be possible to remove deprecation_filter Monolog handler in the Monolog bundle recipe.
yes! and we could move them to a NullLogger by default for the prod env
9867d58
to
18200f8
Compare
Do you mean to use the same handler(s) as |
Yes, that's a possibility. I fear that logging deprecations to a new channel might break apps that configured the php channel and expect deprecations to go there. Ideally, we'd figure out a way to make the new channel opt-in somehow. |
Logging to specific channel is now disabled by default (the service |
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.
Nice!
Please consider a doc PR as this will have to be documented appropriately.
fe30f8a
to
3d415cb
Compare
Thank you @l-vo. |
PR to documentation added |
This PR allows to activate a specific channel for deprecations.
Base configuration
Deprecation specific channel enabled: