Issue
I have migrated an application from Symfony 3.4 to Symfony 4.4.
Now I have a lot of deprecations for each request/ Sf command (I can't fix that deprecations).
How can I exclude deprecations from the log for this Symfony App?
Solution
Exclude the php
channel from the main log handler:
config/packages/prod/monolog.yaml:
monolog:
handlers:
main:
type: stream
path: %kernel.logs_dir%/%kernel.environment%.log
level: debug
formatter: monolog.formatter.session_request
channels:
- '!php' # <----------- add this line
Leave deprecation messages in the dev
mode though. You should be aware of the changes in upstream packages.
Answered By - emix
0 Comments:
Post a Comment
Note: Only a member of this blog may post a comment.