今天在调试一个golang项目时,从github上拉取项目,安照以往的步骤
git clone https://github.com/xxxx
cd xxxx
go mod tidy
但当
go mod tidy
拉取依赖包里报:
go mod tidy: go.mod file indicates go 1.17, but maximum supported version is 1.16
大概的意思是golang的版本太低了,于是就直接用
下载最新版本安装包后覆盖原来的版本
然后再运行
go mod tidy
就正常了

在调试Golang项目时遇到问题,由于Go版本低于项目需求,执行`go mod tidy`时报错。更新Go语言到最新版本后,问题得到解决,能够正常运行`go mod tidy`。

1120

被折叠的 条评论
为什么被折叠?



