当前位置: 首页 > news >正文

go语言相关bug

第一个bug

itcast@itcast:/home/jian/share/src/go-test/homeweb-client$ go mod tidy
go: finding module for package github.com/micro/go-grpc
go: found github.com/micro/go-grpc in github.com/micro/go-grpc v1.0.1
go: homeweb-client/handler importsgithub.com/micro/go-grpc importsgithub.com/micro/go-micro importsgithub.com/micro/go-micro/cmd importsgithub.com/micro/go-micro/registry/consul importsgithub.com/hashicorp/consul/watch tested bygithub.com/hashicorp/consul/watch.test importsgithub.com/hashicorp/consul/agent importsgithub.com/hashicorp/go-discover importsgithub.com/hashicorp/go-discover/provider/azure importsgithub.com/Azure/go-autorest/autorest: ambiguous import: found package github.com/Azure/go-autorest/autorest in multiple modules:github.com/Azure/go-autorest v11.7.0+incompatible (/home/jian/share/pkg/mod/github.com/!azure/go-autorest@v11.7.0+incompatible/autorest)github.com/Azure/go-autorest/autorest v0.9.0 (/home/jian/share/pkg/mod/github.com/!azure/go-autorest/autorest@v0.9.0)
go: homeweb-client/handler importsgithub.com/micro/go-grpc importsgithub.com/micro/go-micro importsgithub.com/micro/go-micro/cmd importsgithub.com/micro/go-micro/registry/consul importsgithub.com/hashicorp/consul/watch tested bygithub.com/hashicorp/consul/watch.test importsgithub.com/hashicorp/consul/agent importsgithub.com/hashicorp/go-discover importsgithub.com/hashicorp/go-discover/provider/azure importsgithub.com/Azure/go-autorest/autorest/adal: ambiguous import: found package github.com/Azure/go-autorest/autorest/adal in multiple modules:github.com/Azure/go-autorest v11.7.0+incompatible (/home/jian/share/pkg/mod/github.com/!azure/go-autorest@v11.7.0+incompatible/autorest/adal)github.com/Azure/go-autorest/autorest/adal v0.5.0 (/home/jian/share/pkg/mod/github.com/!azure/go-autorest/autorest/adal@v0.5.0)
go: homeweb-client/handler importsgithub.com/micro/go-grpc importsgithub.com/micro/go-micro importsgithub.com/micro/go-micro/cmd importsgithub.com/micro/go-micro/registry/consul importsgithub.com/hashicorp/consul/watch tested bygithub.com/hashicorp/consul/watch.test importsgithub.com/hashicorp/consul/agent importsgithub.com/hashicorp/go-discover importsgithub.com/hashicorp/go-discover/provider/azure importsgithub.com/Azure/go-autorest/autorest/azure: ambiguous import: found package github.com/Azure/go-autorest/autorest/azure in multiple modules:github.com/Azure/go-autorest v11.7.0+incompatible (/home/jian/share/pkg/mod/github.com/!azure/go-autorest@v11.7.0+incompatible/autorest/azure)github.com/Azure/go-autorest/autorest v0.9.0 (/home/jian/share/pkg/mod/github.com/!azure/go-autorest/autorest@v0.9.0/azure)
go: homeweb-client/handler importsgithub.com/micro/go-grpc importsgithub.com/micro/go-micro importsgithub.com/micro/go-micro/cmd importsgithub.com/micro/go-micro/registry/consul importsgithub.com/hashicorp/consul/watch tested bygithub.com/hashicorp/consul/watch.test importsgithub.com/hashicorp/consul/agent importsgithub.com/hashicorp/go-discover importsgithub.com/hashicorp/go-discover/provider/azure importsgithub.com/Azure/azure-sdk-for-go/services/network/mgmt/2015-06-15/network importsgithub.com/Azure/go-autorest/autorest/to: ambiguous import: found package github.com/Azure/go-autorest/autorest/to in multiple modules:github.com/Azure/go-autorest v11.7.0+incompatible (/home/jian/share/pkg/mod/github.com/!azure/go-autorest@v11.7.0+incompatible/autorest/to)github.com/Azure/go-autorest/autorest/to v0.2.0 (/home/jian/share/pkg/mod/github.com/!azure/go-autorest/autorest/to@v0.2.0)
go: homeweb-client/handler importsgithub.com/micro/go-grpc importsgithub.com/micro/go-micro importsgithub.com/micro/go-micro/cmd importsgithub.com/micro/go-micro/registry/consul importsgithub.com/hashicorp/consul/watch tested bygithub.com/hashicorp/consul/watch.test importsgithub.com/hashicorp/consul/agent importsgithub.com/hashicorp/go-discover importsgithub.com/hashicorp/go-discover/provider/azure importsgithub.com/Azure/azure-sdk-for-go/services/network/mgmt/2015-06-15/network importsgithub.com/Azure/go-autorest/autorest/validation: ambiguous import: found package github.com/Azure/go-autorest/autorest/validation in multiple modules:github.com/Azure/go-autorest v11.7.0+incompatible (/home/jian/share/pkg/mod/github.com/!azure/go-autorest@v11.7.0+incompatible/autorest/validation)github.com/Azure/go-autorest/autorest/validation v0.1.0 (/home/jian/share/pkg/mod/github.com/!azure/go-autorest/autorest/validation@v0.1.0)
go: homeweb-client/handler importsgithub.com/micro/go-grpc importsgithub.com/micro/go-micro importsgithub.com/micro/go-micro/cmd importsgithub.com/micro/go-micro/registry/consul importsgithub.com/hashicorp/consul/watch tested bygithub.com/hashicorp/consul/watch.test importsgithub.com/hashicorp/consul/agent importsgithub.com/hashicorp/go-discover importsgithub.com/hashicorp/go-discover/provider/azure importsgithub.com/Azure/azure-sdk-for-go/services/network/mgmt/2015-06-15/network importsgithub.com/Azure/go-autorest/tracing: ambiguous import: found package github.com/Azure/go-autorest/tracing in multiple modules:github.com/Azure/go-autorest v11.7.0+incompatible (/home/jian/share/pkg/mod/github.com/!azure/go-autorest@v11.7.0+incompatible/tracing)github.com/Azure/go-autorest/tracing v0.5.0 (/home/jian/share/pkg/mod/github.com/!azure/go-autorest/tracing@v0.5.0)
itcast@itcast:/home/jian/share/src/go-test/homeweb-client$ ls

https://github.com/Azure/go-autorest 去这个官网去安装

go get github.com/Azure/go-autorest/autorest
go get github.com/Azure/go-autorest/autorest/azure
go get github.com/Azure/go-autorest/autorest/date
go get github.com/Azure/go-autorest/autorest/to
github.com/Shopify/sarama: github.com/Shopify/sarama@v1.42.1: parsing go.mod:
module declares its path as: github.com/IBM/saramabut was required as: github.com/Shopify/sarama

出现这种情况可能是版本的问题

replace github.com/golang/lint => golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3replace github.com/testcontainers/testcontainer-go => github.com/testcontainers/testcontainers-go v0.0.2replace github.com/envoyproxy/go-control-plane => github.com/envoyproxy/go-control-plane v0.8.1
http://www.lryc.cn/news/227893.html

相关文章:

  • Spring Cloud OpenFeign:基于Ribbon和Hystrix的声明式服务调用
  • 租用服务器带宽类型应用
  • SOLIDWORKS实用技巧之焊件轮廓应用
  • 本地浏览器全局翻译 demo 以火狐firefox为例【免费-简单】
  • 使用多线程处理List数据
  • Elasticsearch--Python使用、Django/Flask集成
  • pyspark将数据多次插入表的时候报错
  • Qt绘制饼状图
  • Vue3 setup函数
  • Django(三、数据的增删改查、Django生命周期流程图)
  • Linux 部署Sentinel控制台
  • 服务器如何下载百度网盘数据
  • POJ 3254 Corn Fields 状态压缩DP(铺砖问题)
  • transformers安装避坑
  • 牛客、赛码网OJ调试(全)
  • 【CSS】全局声明引入自定义字体
  • 「Flask」路由+视图函数
  • 信息系统项目管理师 教材目录、考试大纲、考情
  • python线性回归实现
  • 【JavaEESpring】认识Spring
  • Rust逆向学习 (5)
  • 89.STL-函数对象的使用(仿函数)
  • 文件管理技巧:按文件容量大小分类,自动移动至目标文件夹的方法
  • [架构之路-246]:目标系统 - 设计方法 - 软件工程 - 需求工程- 需求开发:获取、分析、定义、验证
  • 轻量日志管理方案-[EFK]
  • Halcon WPF 开发学习笔记:HSmartWindowControlWPF正常加载
  • mybatis的简单教程
  • 数据结构 队列(C语言实现)
  • Android---屏幕适配的处理技巧
  • vmware workstation 与 device/credential guard 不兼容