-
-
Notifications
You must be signed in to change notification settings - Fork 176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Breakpoints set offline never reached #320
Comments
Please see bmewburn/vscode-intelephense#1865 and parent issue microsoft/vscode#112231 |
Hi! I'm not sure I'm getting all the information here. The issue is very old (2018) and in the mean time the path mapping code was improved to handle different drive letter cases and other edge cases. One of the referenced issues mentions UNC paths. I'm guessing you are doing some sort of remote debugging (linux+samba). I had good experience with UNC mappings ( I'm not sure how you got to the point where one file was opened twice (with different paths), but a mapping of I suggest you also try VSCode Remote SSH. Let me know if this answers some of your questions and if not, we can define a problem more exactly so I can try to reproduce it. |
Sorry, if I was needlessly abrupt. |
Hi! |
How to create the logs? That's probably the hardest part for me :) |
Hi! |
Hi. I do see some strange things I need to investigate. Here two breakpoints being set from VSCODE to DAP:
and
Being later transformed and sent to XDEBUG
As seen here, the second one is not properly mapped.
If I add case insensitivity here, what is going to happen when the breakpoint is triggered? And the plugin needs to map the path back to UNC? It will map it to uppercase UNC because that is what is in Can you try to figure out when you get an uppercase UNC and when a lower case (when opening files and workspace in VSCode)? |
Because it's a bug in VS Code. It doesn't do path normalization in all necessary cases.
Until the bug is fixed, it should uppercase host names of UNC paths on Windows. |
I'm looking into it. Have managed to compile and run the intelephense extension and got a trace of LSP messages (this helped: https://code.visualstudio.com/api/language-extensions/language-server-extension-guide). I need to setup a linux share to test it, but already tried it with WSL and there it seems that VSCode sees UNC with lowercase "host".
PHP on the other hand, does strange things:
And because of that, also Xdebug:
I've already opened a bug with Xdebug, but this is a larger issue than just Xdebug. Its a PHP issue. https://bugs.xdebug.org/view.php?id=1964 I could also get VSCode to open different versions of the folder by running from command line:
I did almost get things working by opening the folder with
However, setting breakpoints is still broken because the reverse computation just can't figure it out: My suggestion right now, try to assign a drive letter to he UNC path and open the folder with something like I'll try to come back around this strange case, and at least figure out where the core of the problem lies... |
WSL paths are a bigger headache than regular UNC paths. Probably (PROBABLY!) an easy achievements would be to compare host and first path component of the breakpoint caselessly on Windows. So, say, Assigning drive letters is a big security hole I learned to avoid in my younger years. |
PHP version: any
XDebug version: any
Adapter version: 1.12.6
VS Code: 1.29.1/Win64
Your launch.json:
XDebug php.ini config: irrelevant
Code snippet to reproduce: any code
See attached image:
This is the same physical file.
The first (enabled) breakpoint was set when no debugger was connected. (Open from Explorer, scroll to line and hit F9.)
The second (disabled) breakpoint was set when a debugging session was inside the file in question.
Clicking on the breakpoints open TWO editing tabs.
I just can't wrap my mind around necessary
pathMappings
configuration. Already tried several positions with no success. Two "working" (as in, not breaking anything) variants are in the sample comments. But they do not change anything significantly.The project is on local drive, VS Code opened at project root, all proper.
The text was updated successfully, but these errors were encountered: