dongshao1981 2015-10-22 06:04
浏览 32
已采纳

Golang的“内部错误:重复加载”-如何解决此错误?

I am new in go. I have used external package in my project. I have tried to the below command for getting all imported packages,

go get -v all

It will throw duplicate loads error. What is the problem of this. How can I resolve this error ?

go get -v all
internal error: duplicate loads of unsafe
internal error: duplicate loads of runtime
internal error: duplicate loads of errors
internal error: duplicate loads of sync/atomic
internal error: duplicate loads of sync
internal error: duplicate loads of io
internal error: duplicate loads of unicode
internal error: duplicate loads of unicode/utf8
internal error: duplicate loads of bytes
internal error: duplicate loads of bufio
internal error: duplicate loads of math
internal error: duplicate loads of strconv
internal error: duplicate loads of reflect
internal error: duplicate loads of encoding/binary
internal error: duplicate loads of syscall
internal error: duplicate loads of time
internal error: duplicate loads of os
internal error: duplicate loads of fmt
internal error: duplicate loads of sort
internal error: duplicate loads of strings
internal error: duplicate loads of path/filepath
internal error: duplicate loads of path
  • 写回答

1条回答 默认 最新

  • 普通网友 2015-10-22 06:12
    关注

    Do not use all as argument to go get. That's not how it works.

    "all" ist special and means "the whole standard library" and you don't need (and cannot) go get the standard library (as it is part of your Go installation).

    Take a close look at the documentation of the go tool, e.g. by go help or go help get. To get an external package foo/bar/baz use go get foo/bar/baz.

    There is no (simple, newbie suitable) way to get all imported external packages. The most sensible way is to go get the/external/package and then use it in your code, not the other way around.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 关于#matlab#的问题:在模糊控制器中选出线路信息,在simulink中根据线路信息生成速度时间目标曲线(初速度为20m/s,15秒后减为0的速度时间图像)我想问线路信息是什么
  • ¥15 banner广告展示设置多少时间不怎么会消耗用户价值
  • ¥16 mybatis的代理对象无法通过@Autowired装填
  • ¥15 可见光定位matlab仿真
  • ¥15 arduino 四自由度机械臂
  • ¥15 wordpress 产品图片 GIF 没法显示
  • ¥15 求三国群英传pl国战时间的修改方法
  • ¥15 matlab代码代写,需写出详细代码,代价私
  • ¥15 ROS系统搭建请教(跨境电商用途)
  • ¥15 AIC3204的示例代码有吗,想用AIC3204测量血氧,找不到相关的代码。