I am trying to see the traceLine on Yii2 debug bar like explains in (https://github.com/yiisoft/yii2-debug#open-files-in-ide), but I can’t see it.
I have Yii2 2.0.28 and debug-bar 2.1.9
I am trying to see the traceLine on Yii2 debug bar like explains in (https://github.com/yiisoft/yii2-debug#open-files-in-ide), but I can’t see it.
I have Yii2 2.0.28 and debug-bar 2.1.9
Where do you expect to see it?
I remember some time ago I can see in debugbar a link to my IDE in order to edit the exact line of the trace, but I didn’t remember more.
Was not there any way to view the script line who generate a trace, or a profile calling?
Well, you can use Chrome debugger in order to inspect HTML looking for “phpstorm://open”. traceLine
option, as I remember, isn’t visible visually but class and method names in the trace are becoming click-able.
For example: is there any way, inspecting any debug bar’s panel, to know which line of my code thrown a trace/profile action in the debug bar?
Or how can I see where is located any query I am seeing in the database panel?
Do you mean that?
You could find it in the Logs Panel debug/default/view?panel=log
My Config:
$config['bootstrap'][] = 'debug';
$config['modules']['debug'] = [
'class' => 'yii\debug\Module',
'traceLine' => '<a href="phpstorm://open?url={file}&line={line}">{file}:{line}</a>',
'allowedIPs' => ['*'],
'panels' => [
'db' => [
'class' => 'yii\debug\panels\DbPanel',
'defaultOrder' => [
'seq' => SORT_ASC
],
'defaultFilter' => [
'type' => 'SELECT'
]
],
],
];
I had exactly your same columns, but not the lines of code under “select * from …”; that is not showing for me.
And I have exactly your same debug configuration.
Can you paste your config?
Which Version of Yii2 are you using? Upper left Corner of your Debug Panel
On my first post I indicated the versions:
I have Yii2 2.0.28 and debug-bar 2.1.9
This is my config:
$config['bootstrap'][] = 'debug';
$config['modules']['debug'] = [
'class' => 'yii\debug\Module',
'allowedIPs' => ['*'],
'traceLine' => '<a href="phpstorm://open?url={file}&line={line}">{file}:{line}</a>',
'panels' => [
'db' => [
'class' => 'yii\debug\panels\DbPanel',
'defaultOrder' => [
'seq' => SORT_ASC
],
'defaultFilter' => [
'type' => 'SELECT'
]
],
],
];
Forget to ask for your php Version
php 7.2.19
The solution was here:
https://www.yiiframework.com/doc/guide/2.0/en/runtime-logging#trace-level
I must include 'traceLevel' => 3
in configuration