-
Notifications
You must be signed in to change notification settings - Fork 763
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
Debug: couldn't start dlv-dap #1693
Comments
i have this issue as well |
i have fixxed it but dlv-dap doesn't work add this config into "setting.json"
but,command "dlv-dap dap --listen=:12345 --log --log-output=dap" doesn't work |
@miao233 Please share what you see when you run "dlv-dap dap --listen=:12345 --log --log-output=dap". If you are using windows, find where your dlv-dap.exe is installed and run `dlv-dap.exe dap --listen=:12345 --log --log-output=dap" |
I'm not the original poster, but since I also ran into this issue, I thought I'd comment here to follow. The output of the above command is fine, the DAP server starts successfully.
|
@malaclypse |
@hyangah, i also run into this - vs code v1.59, go v1.16.7 - when i run the dlv dap command listed above manually, it takes about 14 seconds. |
Change https://golang.org/cl/342632 mentions this issue: |
@hyangah i found the problem,cause firewall & safety-critical software had stopped dlv-dap on Windows with the latest VSCode and Go.i think maybe dlv-dap is new for windows? anyway,it work, it takes about 2 seconds. |
@hyangah I see now that if I run start the server in a terminal outside of VSCode it's instantaneous, but it takes between 7 and 9 seconds inside the VSCode terminal, I'm honestly not sure what could be causing the discrepancy. I'm using the Windows Terminal app when outside of VSCode as my terminal, and it doesn't matter if I'm running it in CMD or a Powershell Core session (same for VSCode, in any shell it's much slower). |
Some users are experiencing slow dlv dap server start. The root cause of this slow start still needs investigation. For #1693 Change-Id: Ie932bc2b9b7d273e0be2553b9fc154f2ae0b3ead Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/342632 Trust: Hyang-Ah Hana Kim <[email protected]> Reviewed-by: Suzy Mueller <[email protected]>
Change https://golang.org/cl/345550 mentions this issue: |
Some users are experiencing slow dlv dap server start. The root cause of this slow start still needs investigation. For #1693 Change-Id: Ie932bc2b9b7d273e0be2553b9fc154f2ae0b3ead Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/342632 Trust: Hyang-Ah Hana Kim <[email protected]> Reviewed-by: Suzy Mueller <[email protected]> (cherry picked from commit c79e0c4) Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/345550 Run-TryBot: Hyang-Ah Hana Kim <[email protected]> TryBot-Result: kokoro <[email protected]> Trust: Suzy Mueller <[email protected]>
I'm seeing the same thing on VSCode on linux (Fedora 34 FWIW). Running
If I start dlv-dap externally, and point my launch.conf to use the appropriate port My launch.conf (in case it is helpful): {
"name": "CloudCredOperator",
"type": "go",
//"debugAdapter": "legacy",
"request": "launch",
"mode": "auto",
"remotePath": "",
"port": 12345,
"host": "127.0.0.1",
"program": "${env:HOME}/projects/cloud-credential-operator/src/github.com/openshift/cloud-credential-operator/cmd/cloud-credential-operator/main.go",
"env": {
"KUBECONFIG": "/home/jdiaz/.kube/aws.kubeconfig",
"CCO_SKIP_LEADER_ELECTION": "yes",
"RELEASE_VERSION": "NEWTESTVER"
},
"args": [
"operator"//,
//"--log-level=debug"
],
"showLog": true
}, |
Change https://golang.org/cl/351251 mentions this issue: |
Is this still an issue?
And, other than these, I am currently out of ideas. :-( |
Closing. The dlv-dap path had been default for a while and I don't see much activity here for a few months. |
https://stackoverflow.com/questions/68753251/couldnt-start-dlv-dap
launch.json:
I suspect the default timeout (5sec) is too short, or some other bug prevented the dlv dap server from starting:
If any of you encountered an issue, can you please try the following command and time how long it takes?
The text was updated successfully, but these errors were encountered: