laravel突然出现[2017-10-22 09:51:01] production.ERROR: exception 'RuntimeException' with message 'Directory name must not be empty.' in F:\xiangmu\tms\vendor\symfony\finder\Iterator\RecursiveDirectoryIterator.php:54 Stack trace:错误
展开阅读全文

今天在laravel5.4开发中,突然出现这个错误,瞬间我就楞逼了

Whoops, looks like something went wrong.

what?然后去storage/logs/laravel.log看了下报错日记

[2017-10-22 09:51:01] production.ERROR: exception 'RuntimeException' with message 'Directory name must not be empty.' in F:\xiangmu\tms\vendor\symfony\finder\Iterator\RecursiveDirectoryIterator.php:54
Stack trace:
#0 F:\xiangmu\tms\vendor\symfony\finder\Iterator\RecursiveDirectoryIterator.php(54): RecursiveDirectoryIterator->__construct('', 4096)
#1 F:\xiangmu\tms\vendor\symfony\finder\Finder.php(669): Symfony\Component\Finder\Iterator\RecursiveDirectoryIterator->__construct('', 4096, false)
#2 F:\xiangmu\tms\vendor\symfony\finder\Finder.php(571): Symfony\Component\Finder\Finder->searchInDirectory('')
#3 F:\xiangmu\tms\vendor\laravel\framework\src\Illuminate\Foundation\Bootstrap\LoadConfiguration.php(87): Symfony\Component\Finder\Finder->getIterator()
#4 F:\xiangmu\tms\vendor\laravel\framework\src\Illuminate\Foundation\Bootstrap\LoadConfiguration.php(64): Illuminate\Foundation\Bootstrap\LoadConfiguration->getConfigurationFiles(Object(Illuminate\Foundation\Application))
#5 F:\xiangmu\tms\vendor\laravel\framework\src\Illuminate\Foundation\Bootstrap\LoadConfiguration.php(39): Illuminate\Foundation\Bootstrap\LoadConfiguration->loadConfigurationFiles(Object(Illuminate\Foundation\Application), Object(Illuminate\Config\Repository))
#6 F:\xiangmu\tms\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(208): Illuminate\Foundation\Bootstrap\LoadConfiguration->bootstrap(Object(Illuminate\Foundation\Application))
#7 F:\xiangmu\tms\vendor\laravel\framework\src\Illuminate\Foundation\Http\Kernel.php(162): Illuminate\Foundation\Application->bootstrapWith(Array)
#8 F:\xiangmu\tms\vendor\laravel\framework\src\Illuminate\Foundation\Http\Kernel.php(146): Illuminate\Foundation\Http\Kernel->bootstrap()
#9 F:\xiangmu\tms\vendor\laravel\framework\src\Illuminate\Foundation\Http\Kernel.php(116): Illuminate\Foundation\Http\Kernel->sendRequestThroughRouter(Object(Illuminate\Http\Request))
#10 F:\xiangmu\tms\public\index.php(53): Illuminate\Foundation\Http\Kernel->handle(Object(Illuminate\Http\Request))
#11 {main}

什么鬼,排查了一大推问题,没发现什么错误哈。回想刚才的一幕幕,在想我肯定误加和误点了什么。查了好久,终于发现问题了。因为手误原因,把config文件拉到了app文件夹里面。哎,把他拉出来就没事了。