Suddenly any of the migration command is not working in my project and i don't know why. following is the errors in cmd.
C:\wamp64\www\project>yii migrate
Exception 'yii\base\InvalidConfigException' with message 'Failed to instantiate component or class "user".'
in C:\wamp64\www\project\vendor\yiisoft\yii2\di\Instance.php:139
Stack trace:
#0 C:\wamp64\www\project\vendor\yiisoft\yii2\filters\AccessControl.php(100): yii\di\Instance::ensure(Object(yii\di\Instance), 'yii\\web\\User')
#1 C:\wamp64\www\project\vendor\yiisoft\yii2\base\Object.php(107): yii\filters\AccessControl->init()
#2 [internal function]: yii\base\Object->__construct(Array)
#3 C:\wamp64\www\project\vendor\yiisoft\yii2\di\Container.php(381): ReflectionClass->newInstanceArgs(Array)
#4 C:\wamp64\www\project\vendor\yiisoft\yii2\di\Container.php(156): yii\di\Container->build('yii\\filters\\Acc...', Array, Array)
#5 C:\wamp64\www\project\vendor\yiisoft\yii2\BaseYii.php(348): yii\di\Container->get('yii\\filters\\Acc...', Array, Array)
#6 C:\wamp64\www\project\vendor\yiisoft\yii2\base\Component.php(183): yii\BaseYii::createObject(Array)
#7 C:\wamp64\www\project\vendor\yiisoft\yii2\BaseYii.php(529): yii\base\Component->__set('beforeRequest', Array)
#8 C:\wamp64\www\project\vendor\yiisoft\yii2\base\Object.php(105): yii\BaseYii::configure(Object(yii\console\Application), Array)
#9 C:\wamp64\www\project\vendor\yiisoft\yii2\base\Application.php(205): yii\base\Object->__construct(Array)
#10 C:\wamp64\www\project\vendor\yiisoft\yii2\console\Application.php(89): yii\base\Application->__construct(Array)
#11 C:\wamp64\www\project\yii(26): yii\console\Application->__construct(Array)
#12 {main}
Please help me to solve it.
Related
I have a local wiki (MediaWiki 1.38.4 ; Apache with xampp) that worked perfectly for a few weeks, but today started giving me errors with the TemplateParser.php and now is completely unnaccesible and shows the following error details:
MediaWiki internal error.
Original exception: [3d60e113338e8a53946d26be] /fangirlbook/index.php/P%C3%A1gina_principal TypeError: Cannot access offset of type string on string
Backtrace:
from C:\xampp\htdocs\fangirlbook\includes\TemplateParser.php(134)
#0 C:\xampp\htdocs\fangirlbook\includes\TemplateParser.php(289): TemplateParser->getTemplate(string)
#1 C:\xampp\htdocs\fangirlbook\includes\skins\SkinMustache.php(65): TemplateParser->processTemplate(string, array)
#2 C:\xampp\htdocs\fangirlbook\skins\Vector\includes\SkinVector.php(455): SkinMustache->generateHTML()
#3 C:\xampp\htdocs\fangirlbook\includes\skins\SkinTemplate.php(150): Vector\SkinVector->generateHTML()
#4 C:\xampp\htdocs\fangirlbook\includes\OutputPage.php(2807): SkinTemplate->outputPage()
#5 C:\xampp\htdocs\fangirlbook\includes\MediaWiki.php(926): OutputPage->output(boolean)
#6 C:\xampp\htdocs\fangirlbook\includes\MediaWiki.php(939): MediaWiki::{closure}()
#7 C:\xampp\htdocs\fangirlbook\includes\MediaWiki.php(563): MediaWiki->main()
#8 C:\xampp\htdocs\fangirlbook\index.php(53): MediaWiki->run()
#9 C:\xampp\htdocs\fangirlbook\index.php(46): wfIndexMain()
#10 {main}
Exception caught inside exception handler: [3d60e113338e8a53946d26be] /fangirlbook/index.php/P%C3%A1gina_principal TypeError: Cannot access offset of type string on string
Backtrace:
from C:\xampp\htdocs\fangirlbook\includes\TemplateParser.php(134)
#0 C:\xampp\htdocs\fangirlbook\includes\TemplateParser.php(289): TemplateParser->getTemplate(string)
#1 C:\xampp\htdocs\fangirlbook\includes\skins\SkinMustache.php(65): TemplateParser->processTemplate(string, array)
#2 C:\xampp\htdocs\fangirlbook\skins\Vector\includes\SkinVector.php(455): SkinMustache->generateHTML()
#3 C:\xampp\htdocs\fangirlbook\includes\skins\SkinTemplate.php(150): Vector\SkinVector->generateHTML()
#4 C:\xampp\htdocs\fangirlbook\includes\OutputPage.php(2807): SkinTemplate->outputPage()
#5 C:\xampp\htdocs\fangirlbook\includes\exception\MWExceptionRenderer.php(157): OutputPage->output()
#6 C:\xampp\htdocs\fangirlbook\includes\exception\MWExceptionRenderer.php(76): MWExceptionRenderer::reportHTML(TypeError)
#7 C:\xampp\htdocs\fangirlbook\includes\exception\MWExceptionHandler.php(107): MWExceptionRenderer::output(TypeError, integer)
#8 C:\xampp\htdocs\fangirlbook\includes\exception\MWExceptionHandler.php(202): MWExceptionHandler::report(TypeError)
#9 C:\xampp\htdocs\fangirlbook\includes\MediaWiki.php(585): MWExceptionHandler::handleException(TypeError, string)
#10 C:\xampp\htdocs\fangirlbook\index.php(53): MediaWiki->run()
#11 C:\xampp\htdocs\fangirlbook\index.php(46): wfIndexMain()
#12 {main}
I have already restarted the system, re-installed the wiki and copying the manual backup I had of the files and the database, and no solution. Any ideas?
Fatal error: Uncaught Error: Call to undefined function get_current_screen() in C:\xampp\htdocs\blueberry-test\wp-includes\script-loader.php:2407 Stack trace: #0 C:\xampp\htdocs\blueberry-test\wp-includes\class-wp-hook.php(307): wp_global_styles_render_svg_filters('') #1 C:\xampp\htdocs\blueberry-test\wp-includes\class-wp-hook.php(331): WP_Hook->apply_filters(NULL, Array) #2 C:\xampp\htdocs\blueberry-test\wp-includes\plugin.php(476): WP_Hook->do_action(Array) #3 C:\xampp\htdocs\blueberry-test\wp-includes\general-template.php(3074): do_action('wp_body_open') #4 C:\xampp\htdocs\blueberry-test\wp-content\themes\blueberrys\header-home.php(35): wp_body_open() #5 C:\xampp\htdocs\blueberry-test\wp-includes\template.php(770): require_once('C:\xampp\htdocs...') #6 C:\xampp\htdocs\blueberry-test\wp-includes\template.php(716): load_template('C:\xampp\htdocs...', true, Array) #7 C:\xampp\htdocs\blueberry-test\wp-includes\general-template.php(48): locate_template(Array, true, true, Array) #8 C:\xampp\htdocs\blueberry-test\wp-content\themes\blueberrys\inc\woocommerce\storefront-woocommerce-template-functions.php(9): get_header('home') #9 C:\xampp\htdocs\blueberry-test\wp-content\themes\blueberrys\functions.php(47): require('C:\xampp\htdocs...') #10 C:\xampp\htdocs\blueberry-test\wp-settings.php(566): include('C:\xampp\htdocs...') #11 C:\xampp\htdocs\blueberry-test\wp-config.php(96): require_once('C:\xampp\htdocs...') #12 C:\xampp\htdocs\blueberry-test\wp-load.php(50): require_once('C:\xampp\htdocs...') #13 C:\xampp\htdocs\blueberry-test\wp-admin\admin.php(34): require_once('C:\xampp\htdocs...') #14 C:\xampp\htdocs\blueberry-test\wp-admin\plugins.php(10): require_once('C:\xampp\htdocs...') #15 {main} thrown in C:\xampp\htdocs\blueberry-test\wp-includes\script-loader.php on line 2407
Please at the description and format your code to code.
I ran composer require 2amigos/yii2-multi-select-widget "*" and after my site went down
An Error occurred while handling another error:
yii\base\InvalidArgumentException: Invalid path alias: #dektrium/rbac/views in C:\xampp\htdocs\webster\vendor\yiisoft\yii2\BaseYii.php:154
Stack trace:
#0 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\Theme.php(144): yii\BaseYii::getAlias('#dektrium/rbac/...')
#1 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\View.php(228): yii\base\Theme->applyTo('C:\\xampp\\htdocs...')
#2 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\web\ErrorHandler.php(266): yii\base\View->renderFile('C:\\xampp\\htdocs...', Array, Object(yii\web\ErrorHandler))
#3 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\web\ErrorHandler.php(126): yii\web\ErrorHandler->renderFile('#yii/views/erro...', Array)
#4 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\ErrorHandler.php(111): yii\web\ErrorHandler->renderException(Object(yii\base\InvalidArgumentException))
#5 [internal function]: yii\base\ErrorHandler->handleException(Object(yii\base\InvalidArgumentException))
#6 {main}
Previous exception:
yii\base\InvalidArgumentException: Invalid path alias: #dektrium/rbac/views in C:\xampp\htdocs\webster\vendor\yiisoft\yii2\BaseYii.php:154
Stack trace:
#0 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\Theme.php(144): yii\BaseYii::getAlias('#dektrium/rbac/...')
#1 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\View.php(228): yii\base\Theme->applyTo('C:\\xampp\\htdocs...')
#2 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\View.php(156): yii\base\View->renderFile('C:\\xampp\\htdocs...', Array, Object(backend\controllers\SiteController))
#3 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\Controller.php(384): yii\base\View->render('index', Array, Object(backend\controllers\SiteController))
#4 C:\xampp\htdocs\webster\backend\controllers\SiteController.php(65): yii\base\Controller->render('index')
#5 [internal function]: backend\controllers\SiteController->actionIndex()
#6 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\InlineAction.php(57): call_user_func_array(Array, Array)
#7 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\Controller.php(157): yii\base\InlineAction->runWithParams(Array)
#8 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\Module.php(528): yii\base\Controller->runAction('', Array)
#9 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\web\Application.php(103): yii\base\Module->runAction('', Array)
#10 C:\xampp\htdocs\webster\vendor\yiisoft\yii2\base\Application.php(386): yii\web\Application->handleRequest(Object(yii\web\Request))
#11 C:\xampp\htdocs\webster\backend\web\index.php(18): yii\base\Application->run()
#12 {main}
It is all that I did. Nothing more nothing less. Just tried to install multi-select and my site went down. Why is that? What can cause this? I tried to remove it composer remove 2amigos/yii2-multi-select-widget and nothing happen. I am totally shocked. Please give me advice!
I am trying to implement Metronic Theme to my Yii-2 advanced application's backend. I followed the instructions on GitHub step by step, however I keep getting a blank page with the following error on it. I am truly stuck.
Here is the error:
An Error occurred while handling another error:
Error: Call to undefined method yii\base\ErrorException::getSeverity() in
C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\ErrorHandler.php:287
Stack trace:
#0 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\ErrorHandler.php(107):
yii\base\ErrorHandler->logException(Object(yii\base\ErrorException))
#1 [internal function]: yii\base\ErrorHandler-
>handleException(Object(yii\base\ErrorException))
#2 {main}
Previous exception:
yii\base\ErrorException: Illegal string offset 'id' in
C:\xampp\htdocs\advanced\vendor\dlds\yii2-metronic\widgets\NavBar.php:59
Stack trace:
#0 C:\xampp\htdocs\advanced\vendor\dlds\yii2-
metronic\widgets\NavBar.php(59): yii\base\ErrorHandler->handleError(2,
'Illegal string ...', 'C:\\xampp\\htdocs...', 59, Array)
#1 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\Object.php(107):
dlds\metronic\widgets\NavBar->init()
#2 [internal function]: yii\base\Object->__construct(Array)
#3 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\di\Container.php(381):
ReflectionClass->newInstanceArgs(Array)
#4 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\di\Container.php(156):
yii\di\Container->build('dlds\\metronic\\w...', Array, Array)
#5 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\BaseYii.php(348):
yii\di\Container->get('dlds\\metronic\\w...', Array, Array)
#6 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\Widget.php(89):
yii\BaseYii::createObject(Array)
#7 C:\xampp\htdocs\advanced\backend\views\layouts\main.php(47):
yii\base\Widget::begin(Array)
#8 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\View.php(330):
require('C:\\xampp\\htdocs...')
#9 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\View.php(250):
yii\base\View->renderPhpFile('C:\\xampp\\htdocs...', Array)
#10 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\Controller.php(396):
yii\base\View->renderFile('C:\\xampp\\htdocs...', Array,
Object(dektrium\user\controllers\SecurityController))
#11 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\Controller.php(382):
yii\base\Controller->renderContent('\n\n <div clas...')
#12 C:\xampp\htdocs\advanced\vendor\dektrium\yii2-
user\controllers\SecurityController.php(166): yii\base\Controller-
>render('login', Array)
#13 [internal function]: dektrium\user\controllers\SecurityController-
>actionLogin()
#14 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\InlineAction.php(57):
call_user_func_array(Array, Array)
#15 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\Controller.php(156):
yii\base\InlineAction->runWithParams(Array)
#16 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\Module.php(523):
yii\base\Controller->runAction('login', Array)
#17 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\web\Application.php(102):
yii\base\Module->runAction('user/security/l...', Array)
#18 C:\xampp\htdocs\advanced\vendor\yiisoft\yii2\base\Application.php(380):
yii\web\Application->handleRequest(Object(yii\web\Request))
#19 C:\xampp\htdocs\advanced\admin\index.php(15): yii\base\Application-
>run()
#20 {main}
You must add 'error' on actions
'rules' => [
[
'actions' => ['error', ...
I got an error during placing order. Order placed half and after that i got error. I checked error.log file i found,
013-11-25 16:35:07 Error: [MissingConnectionException] Database connection "Mysql" is missing, or could not be created.
#0 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/lib/Cake/Model/Datasource/DboSource.php(261): Mysql->connect()
#1 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/lib/Cake/Model/ConnectionManager.php(101): DboSource->__construct(Array)
#2 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/lib/Cake/Model/Model.php(3164): ConnectionManager::getDataSource('default')
#3 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/lib/Cake/Model/Model.php(1096): Model->setDataSource('default')
#4 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/lib/Cake/Model/Model.php(3186): Model->setSource('baskets')
#5 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/lib/Cake/Model/Model.php(2637): Model->getDataSource()
#6 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/app/Model/Basket.php(24): Model->find('first', Array)
#7 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/app/Controller/AppController.php(53): Basket->getSessionDetails('c71b56ada66fd45...')
#8 [internal function]: AppController->beforeFilter(Object(CakeEvent))
#9 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/lib/Cake/Event/CakeEventManager.php(246): call_user_func(Array, Object(CakeEvent))
#10 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/lib/Cake/Controller/Controller.php(669): CakeEventManager->dispatch(Object(CakeEvent))
#11 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/lib/Cake/Routing/Dispatcher.php(183): Controller->startupProcess()
#12 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/lib/Cake/Routing/Dispatcher.php(161): Dispatcher->_invoke(Object(IndexController), Object(CakeRequest), Object(CakeResponse))
#13 /usr/local/pem/vhosts/262731/webspace/httpdocs/parceldirect.ie/app/webroot/index.php(92): Dispatcher->dispatch(Object(CakeRequest), Object(CakeResponse))
#14 {main}
Can anyone suggest me what is the issue with connection? Was server down during order process and got that error? Or any other issue?