Yii2: How do I debug console commands?
PHP Snippet 1:
'log' => [
'targets' => [[
...
], [
'class' => 'yii\log\FileTarget',
'logFile' => '@runtime/logs/profile.log',
'logVars' => [],
'levels' => ['profile'],
'categories' => ['yii\db\Command::query'],
'prefix' => function($message) {
return '';
}
]]
PHP Snippet 2:
[
'class' => 'yii\log\FileTarget',
'levels' => ['info', 'error', 'warning'],
],