Golang 1.11.2: dep ensure failed

Problem:


$ dep ensure
panic: version queue is empty, should not happen
goroutine 1 [running]:
github.com/golang/dep/gps.(*solver).findValidVersion(0xc00021e000, 0xc00026ac80, 0xc0001e6440, 0x1, 0x1, 0x0, 0xc0001e6440)
/home/travis/gopath/src/github.com/golang/dep/gps/solver.go:915 +0x4ec
github.com/golang/dep/gps.(*solver).createVersionQueue(0xc00021e000, 0xc0003ab0c1, 0x14, 0x0, 0x0, 0xc0001e6440, 0x1, 0x1, 0x0, 0x0, ...)
/home/travis/gopath/src/github.com/golang/dep/gps/solver.go:902 +0x46e
github.com/golang/dep/gps.(*solver).solve(0xc00021e000, 0xa64e60, 0xc0000a8188, 0x7c72ab, 0x936c80, 0xc00003c060)
/home/travis/gopath/src/github.com/golang/dep/gps/solver.go:505 +0x611
github.com/golang/dep/gps.(*solver).Solve(0xc00021e000, 0xa64e60, 0xc0000a8188, 0xdfa9c8, 0xc00002c0dc, 0x1f, 0xc00019b5c0)
/home/travis/gopath/src/github.com/golang/dep/gps/solver.go:440 +0xc0
main.(*ensureCommand).runUpdate(0xc000185960, 0xc0000c6980, 0xc00019a860, 0x0, 0x0, 0xc0000f6090, 0xa68f00, 0xc0000afc80, 0xc00002c0c4, 0x37, ...)
/home/travis/gopath/src/github.com/golang/dep/cmd/dep/ensure.go:356 +0x1c0
main.(*ensureCommand).Run(0xc000185960, 0xc0000c6980, 0xc00019a860, 0x0, 0x0, 0x0, 0x0)
/home/travis/gopath/src/github.com/golang/dep/cmd/dep/ensure.go:216 +0x7d4
main.(*Config).Run(0xc0000af0e0, 0x0)
/home/travis/gopath/src/github.com/golang/dep/cmd/dep/main.go:212 +0x1070
main.main()
/home/travis/gopath/src/github.com/golang/dep/cmd/dep/main.go:84 +0x53d
The command "dep ensure -update" failed and exited with 2 during .

Solution:

Add to your Gopkg.toml this lines:


[[override]]
name = "gopkg.in/fsnotify.v1"
source = "gopkg.in/fsnotify/fsnotify.v1"

And try to start dep ensure again.

Leave a Reply

Your email address will not be published. Required fields are marked *