나는 Symfony 3에서 Ubuntu 16.04 용 Symfony2 프로젝트 (Ubuntu 14.04부터)를 구현하려고하는데, 나는 약간의 벽에 부딪쳤다. 작곡가 업데이트 (verbose)를 실행하면 다음과 같은 예외가 발생하고 끝 부분을 추적합니다.이를 정리하는 방법을 모르겠습니다. 내가 뭔가 잘못하고있는 것을 안다. 그러나 예외는 문제가있는 곳을 정확히 찾아 내는데 도움이되지 않는다. 누구나이 문제에 부딪치게되고 가능한 범인을 알고 있습니까?Symfony 3 작곡가 업데이트 ContextErrorException
[Symfony\Component\Debug\Exception\ContextErrorException]
Warning: Invalid argument supplied for foreach()
Script Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache handling the symfony-scripts event terminated with an exception
[RuntimeException]
An error occurred when executing the "'cache:clear --no-warmup'" command:
[Symfony\Component\Debug\Exception\ContextErrorException]
Warning: Invalid argument supplied for foreach()
Exception trace:
() at /vendor/sensio/distribution-bundle/Composer/ScriptHandler.php:293
Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::executeCommand() at /vendor/sensio/distribution-bundle/Composer/ScriptHandler.php:143
Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache() at /usr/share/php/Composer/EventDispatcher/EventDispatcher.php:238
Composer\EventDispatcher\EventDispatcher->executeEventPhpScript() at /usr/share/php/Composer/EventDispatcher/EventDispatcher.php:192
Composer\EventDispatcher\EventDispatcher->doDispatch() at /usr/share/php/Composer/EventDispatcher/EventDispatcher.php:79
Composer\EventDispatcher\EventDispatcher->dispatch() at /usr/share/php/Composer/EventDispatcher/EventDispatcher.php:177
Composer\EventDispatcher\EventDispatcher->doDispatch() at /usr/share/php/Composer/EventDispatcher/EventDispatcher.php:94
Composer\EventDispatcher\EventDispatcher->dispatchScript() at /usr/share/php/Composer/Installer.php:337
Composer\Installer->run() at /usr/share/php/Composer/Command/UpdateCommand.php:173
Composer\Command\UpdateCommand->execute() at /usr/share/php/Symfony/Component/Console/Command/Command.php:256
Symfony\Component\Console\Command\Command->run() at /usr/share/php/Symfony/Component/Console/Application.php:841
Symfony\Component\Console\Application->doRunCommand() at /usr/share/php/Symfony/Component/Console/Application.php:189
Symfony\Component\Console\Application->doRun() at /usr/share/php/Composer/Console/Application.php:166
Composer\Console\Application->doRun() at /usr/share/php/Symfony/Component/Console/Application.php:120
Symfony\Component\Console\Application->run() at /usr/share/php/Composer/Console/Application.php:99
Composer\Console\Application->run() at /usr/bin/composer:44
clearCache가 실패했기 때문에 (수동으로) 캐시 폴더의 내용을 강제로 삭제하고 해당 문제가 해결되었는지 확인하려고합니다. – JimL
나는 그것을 시도했지만 시도하지 않았습니다. – Epicedion
콘솔 명령에서 인수로 null이 포함 된 foreach 또는 실패한 새 번들을 포함하는 최근에 추가 된 코드를 찾습니다. –