The go-to PHP IDE with extensive out-of-the-box support for Laravel and its ecosystem.

Larabug

larabug/larabug image

Larabug stats

Downloads
242.8K
Stars
255
Open Issues
9
Forks
53

View on GitHub →

Laravel 6.x/7.x/8.x/9.x bug notifier

LaraBug

Laravel 6.x/7.x/8.x/9.x package for logging errors to larabug.com

Installation on laravel

You can install the package through Composer.

composer require larabug/larabug

Then publish the config and migration file of the package using the vendor publish command.

php artisan vendor:publish --provider="LaraBug\ServiceProvider"

And adjust config file (config/larabug.php) with your desired settings.

Note: by default only production environments will report errors. To modify this edit your LaraBug configuration.

Installation on lumen

You can install the package through Composer.

composer require larabug/larabug

Copy the config file (larabug.php) to lumen config directory.

php -r "file_exists('config/') || mkdir('config/'); copy('vendor/larabug/larabug/config/larabug.php', 'config/larabug.php');"

And adjust config file (config/larabug.php) with your desired settings.

In bootstrap/app.php you will need to:

  • Uncomment this line:
    $app->withFacades();
  • Register the larabug config file:
    $app->configure('larabug');
  • Register larabug service provider:
    $app->register(LaraBug\ServiceProvider::class);

Configuration variables

All that is left to do is to define two env configuration variables.

LB_KEY=
LB_PROJECT_KEY=

LB_KEY is your profile key which authorises your account to the API.

LB_PROJECT_KEY is your project API key which you've received when creating a project.

Get the variables at larabug.com

Reporting unhandled exceptions

You can use LaraBug as a log-channel by adding the following config to the channels section in config/logging.php:

'channels' => [
// ...
'larabug' => [
'driver' => 'larabug',
],
],

After that you can add it to the stack section:

'channels' => [
'stack' => [
'driver' => 'stack',
'channels' => ['single', 'larabug'],
],
//...
],

PS: If you're using lumen, it could be that you don't have the logging.php file. So, you can use default logging file from framework core and make changes above.

php -r "file_exists('config/') || mkdir('config/'); copy('vendor/laravel/lumen-framework/config/logging.php', 'config/logging.php');"

License

The LaraBug package is open source software licensed under the license MIT

LaraBug photo

Laravel Error Tracker

Cube

Laravel Newsletter

Join 40k+ other developers and never miss out on new tips, tutorials, and more.


Larabug Larabug Related Articles

Laraberg Editor image

Laraberg Editor

Read article
Shift logo

Shift

Running an old Laravel version? Instant, automated Laravel upgrades and code modernization to keep your applications fresh.

Shift
SaaSykit: Laravel SaaS Starter Kit logo

SaaSykit: Laravel SaaS Starter Kit

SaaSykit is a Multi-tenant Laravel SaaS Starter Kit that comes with all features required to run a modern SaaS. Payments, Beautiful Checkout, Admin Panel, User dashboard, Auth, Ready Components, Stats, Blog, Docs and more.

SaaSykit: Laravel SaaS Starter Kit
Harpoon: Next generation time tracking and invoicing logo

Harpoon: Next generation time tracking and invoicing

The next generation time-tracking and billing software that helps your agency plan and forecast a profitable future.

Harpoon: Next generation time tracking and invoicing
Honeybadger logo

Honeybadger

Simple developer-focused application monitoring for Laravel. Error tracking, log management, uptime monitoring, status pages, and more!

Honeybadger
Celebian logo

Celebian

Celebian is a social media marketing agency specializing in helping their clients go viral on TikTok. Whether you're looking to reach a bigger audience or gain more Tiktok followers, likes, and views, they've got you covered.

Celebian
Blastup logo

Blastup

Blastup provides social media enhancement services including buying Instagram likes, followers, and views, with features like instant delivery and a variety of packages to suit different needs.

Blastup