gpt4 book ai didi

php - Laravel 6 : A facade root has not been set

转载 作者:行者123 更新时间:2023-12-04 02:41:41 24 4
gpt4 key购买 nike

之后,我已将我的网站从 Laravel 5.8 迁移到 Laravel 6 Composer 更新 我在网站上有这个错误,也只有一个命令 php工匠 :

PHP Fatal error:  Uncaught RuntimeException: A facade root has not been set. in /var/www/html/vendor/laravel/framework/src/Illuminate/Support/Facades/Facade.php:242
Stack trace:
#0 /var/www/html/app/Exceptions/Handler.php(48): Illuminate\Support\Facades\Facade::__callStatic('check', Array)
#1 /var/www/html/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(376): App\Exceptions\Handler->report(Object(Symfony\Component\Debug\Exception\FatalThrowableError))
#2 /var/www/html/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(141): Illuminate\Foundation\Console\Kernel->reportException(Object(Symfony\Component\Debug\Exception\FatalThrowableError))
#3 /var/www/html/artisan(37): Illuminate\Foundation\Console\Kernel->handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#4 {main}
thrown in /var/www/html/vendor/laravel/framework/src/Illuminate/Support/Facades/Facade.php on line 242

Fatal error: Uncaught RuntimeException: A facade root has not been set. in /var/www/html/vendor/laravel/framework/src/Illuminate/Support/Facades/Facade.php:242
Stack trace:
#0 /var/www/html/app/Exceptions/Handler.php(48): Illuminate\Support\Facades\Facade::__callStatic('check', Array)
#1 /var/www/html/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(376): App\Exceptions\Handler->report(Object(Symfony\Component\Debug\Exception\FatalThrowableError))
#2 /var/www/html/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(141): Illuminate\Foundation\Console\Kernel->reportException(Object(Symfony\Component\Debug\Exception\FatalThrowableError))
#3 /var/www/html/artisan(37): Illuminate\Foundation\Console\Kernel->handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#4 {main}
thrown in /var/www/html/vendor/laravel/framework/src/Illuminate/Support/Facades/Facade.php on line 242

我拿了一个新的 Laravel 6 文件 config\app.php 和一个新的 .env
但总是这个错误...

我该如何解决?

最佳答案

我知道,答案有点晚了 :) 但我仍然相信它可以帮助遇到此问题的其他人。
全部更换str_slug()方法来自 Str::slug()解决问题。
就我而言,我在 config/cache.php 中找到了老 helper 。和 config/session.php文件。

关于php - Laravel 6 : A facade root has not been set,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59084991/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com