You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You have a beforeRender event handler attached to the view component for the console application. The handler is causing you this trouble because it is trying to publish an asset bundle, which shouldn't happen in a console application.
Used "Advanced application template"
Command:
php yii migrate/create create_menu_table
Return exception:
Exception 'yii\base\InvalidParamException' with message 'Invalid path alias: @webroot/assets'
in /var/www/project/vendor/yiisoft/yii2/BaseYii.php:152
Stack trace:
#0 /var/www/project/vendor/yiisoft/yii2/web/AssetManager.php(105): yii\BaseYii::getAlias('@webroot/assets')
#1 /var/www/project/vendor/yiisoft/yii2/base/Object.php(107): yii\web\AssetManager->init()
#2 [internal function]: yii\base\Object->__construct(Array)
#3 /var/www/project/vendor/yiisoft/yii2/di/Container.php(364): ReflectionClass->newInstanceArgs(Array)
#4 /var/www/project/vendor/yiisoft/yii2/di/Container.php(147): yii\di\Container->build('yii\web\AssetMa...', Array, Array)
#5 /var/www/project/vendor/yiisoft/yii2/BaseYii.php(344): yii\di\Container->get('yii\web\AssetMa...', Array, Array)
#6 /var/www/project/vendor/yiisoft/yii2/di/ServiceLocator.php(132): yii\BaseYii::createObject(Array)
#7 /var/www/project/vendor/yiisoft/yii2/di/ServiceLocator.php(70): yii\di\ServiceLocator->get('assetManager')
#8 /var/www/project/common/bundles/requirejs/Requirejs.php(21): yii\di\ServiceLocator->__get('assetManager')
#9 /var/www/project/vendor/yiisoft/yii2/base/Widget.php(96): common\bundles\requirejs\Requirejs->run()
#10 /var/www/project/common/timeweb/yii/Element.php(194): yii\base\Widget::widget(Array)
#11 /var/www/project/common/config/main.php(22): common\timeweb\yii\Element->run(NULL)
#12 [internal function]: {closure}(Object(yii\base\ViewEvent))
#13 /var/www/project/vendor/yiisoft/yii2/base/Component.php(546): call_user_func(Object(Closure), Object(yii\base\ViewEvent))
#14 /var/www/project/vendor/yiisoft/yii2/base/View.php(275): yii\base\Component->trigger('beforeRender', Object(yii\base\ViewEvent))
#15 /var/www/project/vendor/yiisoft/yii2/base/View.php(236): yii\base\View->beforeRender()
#16 /var/www/project/vendor/yiisoft/yii2/base/Controller.php(393): yii\base\View->renderFile('/var/www/project....', Array, Object(yii\console\controllers\MigrateController))
#17 /var/www/project/vendor/yiisoft/yii2/console/controllers/MigrateController.php(526): yii\base\Controller->renderFile('/var/www/project....', Array)
#18 [internal function]: yii\console\controllers\MigrateController->actionCreate('create_menu_tab...')
#19 /var/www/project/vendor/yiisoft/yii2/base/InlineAction.php(54): call_user_func_array(Array, Array)
#20 /var/www/project/vendor/yiisoft/yii2/base/Controller.php(147): yii\base\InlineAction->runWithParams(Array)
#21 /var/www/project/vendor/yiisoft/yii2/console/Controller.php(86): yii\base\Controller->runAction('create', Array)
#22 /var/www/project/vendor/yiisoft/yii2/base/Module.php(429): yii\console\Controller->runAction('create', Array)
#23 /var/www/project/vendor/yiisoft/yii2/console/Application.php(160): yii\base\Module->runAction('migrate/create', Array)
#24 /var/www/project/vendor/yiisoft/yii2/console/Application.php(136): yii\console\Application->runAction('migrate/create', Array)
#25 /var/www/project/vendor/yiisoft/yii2/base/Application.php(367): yii\console\Application->handleRequest(Object(yii\console\Request))
#26 /var/www/project/yii(30): yii\base\Application->run()
#27 {main}
The text was updated successfully, but these errors were encountered: