From 1980ca13eae79cd6f8a5a2f8dc018c289d26e954 Mon Sep 17 00:00:00 2001 From: Nuno Maduro Date: Tue, 19 Oct 2021 14:42:24 +0100 Subject: [PATCH] [8.x] Logs deprecations instead of treating them as exceptions (#5711) * Logs deprecations instead of treating them as exceptions * formatting Co-authored-by: Taylor Otwell --- .env.example | 1 + composer.json | 4 ++-- config/logging.php | 13 +++++++++++++ 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/.env.example b/.env.example index 44853cd5..b7becbac 100644 --- a/.env.example +++ b/.env.example @@ -5,6 +5,7 @@ APP_DEBUG=true APP_URL=http://localhost LOG_CHANNEL=stack +LOG_DEPRECATIONS_CHANNEL=null LOG_LEVEL=debug DB_CONNECTION=mysql diff --git a/composer.json b/composer.json index 3c6d778d..61f49126 100644 --- a/composer.json +++ b/composer.json @@ -8,7 +8,7 @@ "php": "^7.3|^8.0", "fruitcake/laravel-cors": "^2.0", "guzzlehttp/guzzle": "^7.0.1", - "laravel/framework": "^8.54", + "laravel/framework": "^8.65", "laravel/sanctum": "^2.11", "laravel/tinker": "^2.5" }, @@ -18,7 +18,7 @@ "laravel/sail": "^1.0.1", "mockery/mockery": "^1.4.4", "nunomaduro/collision": "^5.10", - "phpunit/phpunit": "^9.5.8" + "phpunit/phpunit": "^9.5.10" }, "autoload": { "psr-4": { diff --git a/config/logging.php b/config/logging.php index 1aa06aa3..880cd922 100644 --- a/config/logging.php +++ b/config/logging.php @@ -19,6 +19,19 @@ 'default' => env('LOG_CHANNEL', 'stack'), + /* + |-------------------------------------------------------------------------- + | Deprecations Log Channel + |-------------------------------------------------------------------------- + | + | This option controls the log channel that should be used to log warnings + | regarding deprecated PHP and library features. This allows you to get + | your application ready for upcoming major versions of dependencies. + | + */ + + 'deprecations' => env('LOG_DEPRECATIONS_CHANNEL', 'null'), + /* |-------------------------------------------------------------------------- | Log Channels