rollbar / rollbar-php-laravel

Rollbar error monitoring integration for Laravel projects
https://docs.rollbar.com/docs/laravel
140 stars 39 forks source link

[4.0.1] Rollbar not reporting for Laravel <= 5.5 #66

Closed patrickcarlohickman closed 5 years ago

patrickcarlohickman commented 6 years ago

In v3.0.4, the RollbarServiceProvider sets up an event listener on Laravel's logger to handle sending the log message on to Rollbar.

In v4.0.0, this event listener was removed, and instead the RollbarServiceProvider binds a new custom exception handler over Laravel's default one, and this custom exception handler is responsible for sending the log message on to Rollbar.

In v4.0.1, this custom exception handler was removed, but the event listener from v3.0.4 was not added back in, so I believe that right now, there is nothing in Laravel <= 5.5 that sends the log message on to Rollbar.

Laravel >= 5.6 still works since the rollbar channel that is setup reports the log message directly to Rollbar.

I would suggest bringing the event listener back, but I believe you'll also need to include a check on Laravel <= 5.5 vs Laravel >= 5.6, since I think the messages would get duplicated in >= 5.6.

Thanks, Patrick

jessewgibbs commented 6 years ago

Thanks for the detailed report, @patrickcarlohickman. We'll investigate this soon and follow-up with you if we need more information.

jessewgibbs commented 6 years ago

@ArturMoczulski any updated on this?

ArturMoczulski commented 5 years ago

@patrickcarlohickman for Laravel <= 5.5 you should be using the v2.* line of releases. Not v4.*.

So if you're using Laravel <= 5.5 please use the latest appropriate release, which is v2.4.1.

All the essential changes are reproduced among both release lines as much as possible.