github.com/stretchr/testify@v1.7.1: Get "https://proxy.golang.org/github.com/stretchr/testify/@v/v1.7.1.zip": dial tcp 172
.217.163.49:443: 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.
解决方法:改成我们国内可用的代理地址
在命令提示符输入: go env -w GOPROXY=https://goproxy.cn
然后再做各种操作就可以成功了
![](https://img.haomeiwen.com/i4222138/d1af7015b4d58738.png)
另外一个问题:
手动下载某些依赖包,但是goland一直无法识别。删掉了GOPATH多余的路径。
![](https://img.haomeiwen.com/i4222138/82a5c236b85c2c73.png)
另外,启用了一下Go Modules。
![](https://img.haomeiwen.com/i4222138/f1cf60019f924265.png)
然后就好了。
网友评论