Visual Studio Code (VSCode) - Error: Debug Adapter Process Has Terminated Unexpectedly

匿名 (未验证) 提交于 2019-12-03 00:59:01

问题:

I'm struggling with this error message. Sometimes I cannot run xdebug on Visual Studio Code after upgrading or restarting the editor. Here's a screenshot of the error:

Can anyone help me with this?

回答1:

After several minutes to find out what happens on my machine, i figure it out how to solve my problem.

Because the xdebug is running based on port 9000 and i see on the Debug Console (VSCode) has message listen EADDRINUSE :::9000, i think there is an another process running on port 9000 so i check what process running on it by this command

sudo netstat -nlp | grep :9000 

The command above will show you what process running on port 9000, then i get this result

tcp6       0      0 :::9000                 :::*                    LISTEN      14856/hhvm 

HHVM was take over port of xdebug by default, so i need to take it service down or change the port number.



回答2:

I had same issue while I was start using VSCode. Well i took 3 hours to figure out what is exactly issue, I just stared with some step by step debugging like what port being used and what are the other settings.

Finally I was lucky and got the solutions :) So I created a page to share with everyone. You can check what is my findings and what you should need to setup to get Xdebug work with VSCode.

Link:

How-to-setup-PHP-Debugging-xdebug-with-VSCode-Visual-Studio-Code

Hope my experience would be helpful for someone. Cheers!!!



标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!