我在Laravel 5.2应用程序中运行 config:cache
,此错误开始显示 .
致命错误:未捕获ReflectionException:类日志不存在于F:\ xampp \ htdocs \ news5.2.23 \ vendor \ laravel \ framework \ src \ Illuminate \ Container \ Container.php:738堆栈跟踪:#0 F:\ xampp \ htdocs \ news5.2.23 \ vendor \ laravel \ framework \ src \ Illuminate \ Container \ Container.php(738):ReflectionClass - > __ construct('log')#1 F:\ xampp \ htdocs \ news5.2.23 \ vendor \ laravel \ framework \ src \ Illuminate \ Container \ Container.php(633):Illuminate \ Container \ Container-> build('log',Array)#2 F:\ xampp \ htdocs \ news5.2.23 \ vendor \ laravel \ framework \ src \ Illuminate \ Foundation \ Application.php(697):Illuminate \ Container \ Container-> make('log',Array)#3 F:\ xampp \ htdocs \ news5.2.23 \ vendor \ laravel \ framework \ src \ Illuminate \ Container \ Container.php(853):Illuminate \ Foundation \ Application-> make('log')#4 F:\ xampp \ htdocs \ news5.2.23 \ vendor \ laravel \ framework \ src \ Illuminate \ Container \ Container .php(808):Illuminate \ Container \ Container-> resolveClass(Object(ReflectionParameter))#5 F:\ xampp \ htdocs \ news5.2.23 \ vendor \ laravel \ framework \ s rc \ Illuminate \ Container \ Container.php(7:F:\ xampp \ htdocs \ news5.2.23 \ vendor \ laravel \ framework \ src \ Illuminate \ Container \ Container.php 738行
我找了很多解决方案 . 没有什么对我有用 .
-
我的
.env
文件没有任何空格 -
我从
composer.json
删除了额外的包并运行composer update
. -
我多次编译
php artisan clear
. -
我在文件中查找错误但找不到任何错误 .
-
我也启用了
mysql
扩展,因为我发现它在某处 . 然后我对Laravel 5.2进行了新的检查,现在错误是这样的 .
所以,这不是我的任何配置文件的问题 . 还有别的东西 . 你们有什么想法吗?
2 回答
好的,所以我解决了 . 看起来谎言我有多个问题 .
我还必须通过编辑php.ini文件来启用我的mysql扩展 .
最后,在我现有的项目中,我实际上在config / app.php中发现了一个问题 . 我错过了某个地方',' . 而人们,laravel是一个恶心的调试器 . 我更想念我的cakephp .
It's a laravel 5 issue. Better to use laravel 4 still
运行此命令:
那么
composer update