-
-
Notifications
You must be signed in to change notification settings - Fork 810
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
[3.3] Core deprecation notice logging #6389
[3.3] Core deprecation notice logging #6389
Conversation
GwendolenLynch
commented
Feb 19, 2017
Deprecation counts based on unit test execution:
|
Won't this affect performance adversely? |
Micro, and obviously only with debugging enabled. This is how Symfony, Silex, and Twig (etc) all do, and literally where @CarsonF and I have been getting all of our recent low hanging … and interestingly enough the discussion between Carson and I two years ago about being able to do this on core, was the start of the very long running attempts to get our exception handling sorted out. In very basic terms, this is why languages like PHP — in this example — have The What we now get with this, is a very clear picture of what it to be done, and how close we're getting, towards replacing both upstream and core use of legacy code. |
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.
WFM. 👍
It just occurred to me to leave this here for those that need it: If you do not want the deprecation notices, nor the small overhead that it introduces when debugging is turned on only, you can adjust your debug_error_level: 16383 # equivalent to E_ALL &~ E_USER_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.
I thought we were going to create a wrapper function for this :(
@@ -45,6 +45,8 @@ public function __construct($directory, $extension = self::EXTENSION, $umask = 0 | |||
*/ | |||
public function clearCache() | |||
{ | |||
@trigger_error(sprintf('%s is deprecated and will be removed in version 4.0. Use flushAll() instead.', __METHOD__)); |
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.
Missing E_USER_DEPRECATED
here.