Hello!
How can I exclude a component from error_log?
It produces useless error messages
It’s already solved since one week
How can error messages be useless?!?
Error messages are always issued by PHP for a good reason,
if something in the code is wrong. Therefore they should not be suppressed but reported to the developer.
Let's have a look at this simple example code to calculate the birthdate:
$current_year = 2023;
$date_of_birth = 2000;
print "Age: " . $current_year - $date_of_birth;
Everything's fine for now and the output will be Age: 23
Same code, but the developer made a typo
$current_year = 2023;
$date_of_birth = 2000;
print "Age: " . $current_yeah - $date_of_birth;
This time, the output will be Age: -2000
and your log shows
Undefined variable $current_yeah in /home/micha/Develop/ex.php on line 3
Actually, PHP would continue here, and if the output wasn't so obviously strange nobody would ever notice the issue without the error log. Thus please provide your logs instead of ignoring or suppressing them.
You can use a level filter to exclude error messages from your error log. Here is an example of how to do it in Logback Spring Boot:
xml
<filter class="ch.qos.logback.classic.filter.LevelFilter">
<level>ERROR</level>
<onMatch>DENY</onMatch>
<onMismatch>ACCEPT</onMismatch>
</filter>
This will exclude all error messages from your error log. You can replace ERROR
with any other log level you want to exclude.
I hope this helps!
See my answer 1 hour ago.
yes, component produces error when someone is not verifies, which makes no sense
You said it is because of component you are getting error log
Which component upgrade?
There is no help it is not possible what you are asking. Wait for the component upgrade.
Any help?
I don't want the complete log to be deactivated, but I get an error from the VerifyUser component which is filling the error log and makes finding problems very difficult
Due to the many requests in the past for additonal features and components we have decided to develope a premium version. Features like Hashtags, Videos, Polls, Events, Stories, Link Preview, etc included in it.
$199 (Life Time)