Closed 1242048704 closed 2 years ago
求教作者大大及路人大佬们🙏🙏🙏
先尝试下单个脚本,比如一个test.php文件。看看能否用上,然后再运用到框架里面。
wsl2 docker 调试 hyperf 没问题,启动命令加上 -e 就行了
php --ri yasd
yasd
Yasd => enabled
Author => codinghuang <codinghuang@qq.com>
Version => 0.3.9-alpha
Built => Apr 20 2022 15:59:59
Directive => Local Value => Master Value
yasd.breakpoints_file => no value => no value
yasd.debug_mode => remote => remote
yasd.remote_host => host.docker.internal => host.docker.internal
yasd.remote_port => 9000 => 9000
yasd.depth => 1 => 1
yasd.log_level => -1 => -1
yasd.max_executed_opline_num => 0 => 0
yasd.init_file => no value => no value
yasd.open_extended_info => 0 => 0
xdebug.coverage_enable => 1 => 1
xdebug.profiler_enable => 1 => 1
xdebug.remote_autostart => 1 => 1
xdebug.remote_connect_back => 0 => 0
xdebug.remote_mode => req => req
launch.json
{
// 使用 IntelliSense 了解相关属性。
// 悬停以查看现有属性的描述。
// 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Listen for XDebug",
"type": "php",
"request": "launch",
"port": 9000
},
{
"name": "Launch currently open script",
"type": "php",
"request": "launch",
"program": "${file}",
"cwd": "${fileDirname}",
"port": 9000
}
]
}
你的wwwroot目录是不是软连接过去的?
你的wwwroot目录是不是软连接过去的?
不要使用软连接,目前调试不了软连接的目录
谢谢大佬们,已解决
在vscode开启监听,wsl2环境下运行代码且在vscode控制台可以看到响应信息并建立Tcp连接的情况下仍然显示不了调试信息