簡體   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