2

when I try to update Craft via CLI to 3.5.1. I get the following error:

Failed to instantiate component or class "yii\shell\Bootstrap
in /vendor/yiisoft/yii2/di/Container.php:449

Stack trace:
#0 /vendor/yiisoft/yii2/di/Container.php(374): yii\di\Container->getDependencies()
#1 /vendor/yiisoft/yii2/di/Container.php(159): yii\di\Container->build()
#2 /vendor/yiisoft/yii2/BaseYii.php(345): yii\di\Container->get()
#3 /vendor/yiisoft/yii2/base/Application.php(294): yii\BaseYii::createObject()
#4 /vendor/craftcms/cms/src/console/Application.php(72): yii\base\Application->bootstrap()
#5 /vendor/yiisoft/yii2/base/Application.php(273): craft\console\Application->bootstrap()
#6 /vendor/yiisoft/yii2/console/Application.php(124): yii\base\Application->init()
#7 /vendor/craftcms/cms/src/console/Application.php(58): yii\console\Application->init()
#8 /vendor/yiisoft/yii2/base/BaseObject.php(109): craft\console\Application->init()
#9 /vendor/yiisoft/yii2/base/Application.php(206): yii\base\BaseObject->__construct()
#10 /vendor/yiisoft/yii2/console/Application.php(89): yii\base\Application->__construct()
#11 /vendor/craftcms/cms/src/console/Application.php(48): yii\console\Application->__construct()
#12 [internal function]: craft\console\Application->__construct()
#13 /vendor/yiisoft/yii2/di/Container.php(400): ReflectionClass->newInstanceArgs()
#14 /vendor/yiisoft/yii2/di/Container.php(159): yii\di\Container->build()
#15 /vendor/yiisoft/yii2/BaseYii.php(365): yii\di\Container->get()
#16 /vendor/craftcms/cms/bootstrap/bootstrap.php(245): yii\BaseYii::createObject()
#17 /vendor/craftcms/cms/bootstrap/console.php(51): require('/var/www/client...')
#18 /craft(21): require('/var/www/client...')
#19 {main}

does anyone know what to do about it?

  • Try to remove/rename your vendor folder then run composer clearcache then composer install – Oli Aug 10 '20 at 9:47
2

This ended up being a bug we were able to work-around on our side via our web service calls.

If you restore your site from a pre-update attempt database backup and composer.json file, then attempt the update again, it should go through fine.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.