编译执行go mod tidy时,出现了这个错误,挺恶心的:

        xxx  requires
        github.com/micro/go-plugins@v1.3.0 requires
        k8s.io/api@v0.0.0-20190726022912-69e1bce1dad5 requires
        github.com/gogo/protobuf@v0.0.0-20190410021324-65acae22fc9: invalid pseudo-version: revision is shorter than canonical

 

        搞了大半天,终于找到原因:

        https://github.com/golang/go/issues/3439

 

        解决办法,在go.mod中加:

replace github.com/gogo/protobuf v0.0.0-20190410021324-65acae22fc9 => github.com/gogo/protobuf v0.0.0-20190723190241-65acae22fc9d

       搞定。

 

 

Logo

K8S/Kubernetes社区为您提供最前沿的新闻资讯和知识内容

更多推荐