前言
参考文章:https://blog.csdn.net/qq_37767455/article/details/121188740
Question
vscode安装dlv依赖时报错:
go: github.com/go-delve/delve/cmd/dlv@latest: module github.com/go-delve/delve/cmd/dlv: Get "https://proxy.golang.org/github.com/go-delve/delve/cmd/dlv/@v/list": dial tcp ***.\*\*\*.\*\*\*.\*\*\*:port: connectex: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
Answer
查看 GOSUMDB 的配置
go env
找到
set GOSUMDB=sum.golang.org
关掉GOSUMDB
go env -w GOSUMDB=off
配置代理
go env -w GOPROXY=https://goproxy.cn,direct
再次安装依赖,成功