mirror of
https://github.com/Seldaek/monolog.git
synced 2026-04-26 08:05:53 +03:00
[PR #870] [MERGED] Make the RavenHandler picks the first highest record as main #1389
Labels
No labels
Bug
Documentation
Feature
Needs Work
Support
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/monolog#1389
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Seldaek/monolog/pull/870
Author: @tucksaun
Created: 10/13/2016
Status: ✅ Merged
Merged: 11/13/2016
Merged by: @Seldaek
Base:
1.x← Head:fix-raven-handler-picking-wrong-event📝 Commits (1)
d234839Make the RavenHandler picks the first highest record as main📊 Changes
2 files changed (+27 additions, -1 deletions)
View changed files
📝
src/Monolog/Handler/RavenHandler.php(+1 -1)📝
tests/Monolog/Handler/RavenHandlerTest.php(+26 -0)📄 Description
Recently in production, I received a lot of sentry notifications for
NotFoundHttpException, which surprised me because we explicitly ignore 404 with a custom activation strategy.After digging a little bit, I found out that the
NotFoundHttpExceptionwas not the real reason to send the error to Sentry, but a previous error was, only the RavenHandler was not picking this one.That lead me to believe that the
RavenHandlershould pick the first highest log message as the main one, which is the more likely to be the one who "triggered" things in the first place, rest becoming only a resultant of it.Moreover, this is more consistent with how the
MailHandleris behaving (github.com/Seldaek/monolog@58544af7ff/src/Monolog/Handler/MailHandler.php (L59-L69)).🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.