rollbar / rollbar-php-laravel

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

laravel.EMERGENCY: Unable to create configured logger. Using emergency logger. #156

Closed jpylisela closed 1 year ago

jpylisela commented 1 year ago

Hi,

getting this error when running the app locally.

[2023-09-29 13:56:32] laravel.EMERGENCY: Unable to create configured logger. Using emergency logger. {"exception":"[object] (Illuminate\\Contracts\\Container\\BindingResolutionException(code: 0): Unresolvable dependency resolving [Parameter #0 [ <required> array $config ]] in class Rollbar\\RollbarLogger

Laravel v10.24.0

rollbar/rollbar-laravel v8.0.0

  'channels' => [
          'stack' => [
              'driver'            => 'stack',
              'channels'          => ['rollbar', 'single'],
              'ignore_exceptions' => false,
          ],

          'single' => [
              'driver' => 'single',
              'path'   => storage_path('logs/laravel.log'),
              'level'  => env('LOG_LEVEL', 'debug'),
          ],

          'rollbar' => [
              'driver'       => 'monolog',
              'handler'      => \Rollbar\Laravel\MonologHandler::class,
              'access_token' => env('ROLLBAR_TOKEN'),
              'environment'  => env('APP_NAME', 'production'),
              'level'        => 'warning',
          ],
jpylisela commented 1 year ago

PHP v8.1

jpylisela commented 1 year ago

Closing as duplicate

https://github.com/rollbar/rollbar-php-laravel/issues/150