繁体   English   中英

Symfony 3作曲家更新ContextErrorException

[英]Symfony 3 composer update ContextErrorException

我正在尝试在适用于Ubuntu 16.04的Symfony 3中实现Symfony2项目(来自Ubuntu 14.04),但遇到了一些麻烦。 当我运行composer update(详细)时,我收到以下异常并最终跟踪,但我不确定如何清除它。 我知道我做错了事,但是该异常并不能帮助您确定问题所在。 有没有人遇到过这个问题并且知道一些可能的罪魁祸首?

 [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

您是否已删除/添加了一个库,却忘记了从AppKernel中删除/添加了它?

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM