Xdebug – breakpoints don’t work
I can’t get breakpoints to work with xdebug. I’m using M1 on Windows
Vista. I’m trying to debug a simple PHP script using the CLI version of
PHP. I have the “PHP -> PHP Executables” settings set properly. But the
IDE will not store the settings that I set under “PHP -> Debug”. I set
Xdebug as my PHP Debugger and set the Default PHP executable, and hit
“Apply” and then “OK”. But when I come back to those settings, they are
back at default with the “Zend Debugger”.bluestacks.vip/ te
——
Re: Xdebug – breakpoints don’t work
IIUC, XDebug is for debugging on a Web-Server, not for CLI.
Nevertheless, I’ve also experienced that the breakpoints do not work – just breaking on the first line works. This is a new problem in 2018-09, it did work in a previous version.
Report message to a moderator
——
Re: Xdebug – breakpoints don’t work
It seems to me that there are (at least) two problems that cause Xdebug / breakpoints to stop working:
1) problems with path mapping
– Eclipse PDT will sometimes confuse path mappings / use wrong path mapping, e.g. on an unrelated Xdebug connection, possibly from the same server.
This is especially dangerous if you have two similar projects and you end up editing wrong files. You can then first wonder why your changes have no effect on the server and later hope to be able to easily undo unwanted changes to the other project.
– When adding path mapping on Windows, it is impossible to enter UNC path like \webwww – error “Path in file system is illegal or not absolute” is shown.
– The Debugger will sometimes fail to get the correct mapping, even if it is explicitly set up. Probably because of (2) –
2) Problems with project mapping and project registration within workspace.
– sometimes when trying to set path mapping between server and workspace, the dialog opened to browse the Workspace will be empty
– sometimes, Xdebug session will be connected and the debugger will accept user input to step through the code, showing the position in the code in the debug pane. But no source file will be open to show the code.
Creating a new workspace and setting up the project from scratch helps to get Xdebug to work, at least for a while.
One time while setting up a project from scratch to b
发表回复