I am just starting to use the PHP Debug extension in Visual Studio Code (Ubuntu 14.04). It mostly works fine for me, but I have a problem that every time an exception is thrown, the debugger automatically breaks. We have lots of exceptions which are internally caught and handled in our code, so I don't want to have to step through each of these.
I've been trying to find something like the Exception Settings in Visual Studio 2015, but can't find any equivalent options within Visual Studio Code.
php.ini settings:
[debug]
xdebug.remote_autostart=on
xdebug.remote_enable=on
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.remote_host=localhost
xdebug.remote_port=9000
Visual Studio Code launch.json:
{
"version": "0.2.0",
"configurations": [
{
"name": "Launch currently open script",
"type": "php",
"request": "launch",
"program": "${file}",
"cwd": "${fileDirname}",
"port": 9000,
"args": ["some arguments"]
}
]
}
Note that when I use Netbeans for debugging with the same xdebug settings and the same codebase, there is no break-on-exception behaviour, so I think this must be something in Visual Studio Code and/or the PHP Debug extension.
Can anyone suggest how to pass through exceptions without breaking?