[GH-ISSUE #815] ErrorHandler only logs error levels set by error_reporting #313

Closed
opened 2026-03-04 02:14:03 +03:00 by kerem · 4 comments
Owner

Originally created by @masterada on GitHub (Jul 6, 2016).
Original GitHub issue: https://github.com/Seldaek/monolog/issues/815

In ErrorHandler.php, we should be able to turn this check off:

    if (!(error_reporting() & $code)) {
        return;
    }

As this check makes it harder to replace legacy error handling with Monolog's error handler.

Originally created by @masterada on GitHub (Jul 6, 2016). Original GitHub issue: https://github.com/Seldaek/monolog/issues/815 In ErrorHandler.php, we should be able to turn this check off: ``` if (!(error_reporting() & $code)) { return; } ``` As this check makes it harder to replace legacy error handling with Monolog's error handler.
kerem closed this issue 2026-03-04 02:14:04 +03:00
Author
Owner

@masterada commented on GitHub (Jul 6, 2016):

#816

<!-- gh-comment-id:230755499 --> @masterada commented on GitHub (Jul 6, 2016): #816
Author
Owner

@keywan-ghadami-oxid commented on GitHub (Jul 28, 2016):

Hi i have the similar problem because the Monolog ErrorHandler stops on this condition it does not even call parent ErrorHandlers which makes it incompatible with other ErrorHandlers.

I did not notice that you already created a pull request please have a look at
https://github.com/keywan-ghadami-oxid/monolog/pull/1/files
Maybe we can combine them what do you think?

<!-- gh-comment-id:235848341 --> @keywan-ghadami-oxid commented on GitHub (Jul 28, 2016): Hi i have the similar problem because the Monolog ErrorHandler stops on this condition it does not even call parent ErrorHandlers which makes it incompatible with other ErrorHandlers. I did not notice that you already created a pull request please have a look at https://github.com/keywan-ghadami-oxid/monolog/pull/1/files Maybe we can combine them what do you think?
Author
Owner

@xabbuh commented on GitHub (Aug 4, 2016):

I guess this can be closed as it was solved by #816 and is part of Monolog 1.21.

<!-- gh-comment-id:237465295 --> @xabbuh commented on GitHub (Aug 4, 2016): I guess this can be closed as it was solved by #816 and is part of Monolog 1.21.
Author
Owner

@Seldaek commented on GitHub (Aug 4, 2016):

Right sorry I missed that it was still open :)

<!-- gh-comment-id:237541186 --> @Seldaek commented on GitHub (Aug 4, 2016): Right sorry I missed that it was still open :)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/monolog#313
No description provided.