Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

GO111MODULE=on (error loading module requirements)

Tags:

go

go get -u github.com/junegunn/fzf works fine but want to test the development branch like so:

gert@gert ~/ GO111MODULE=on go get -u github.com/junegunn/fzf@devel
go: finding github.com/junegunn/fzf devel
go: finding golang.org/x/crypto latest
go: finding github.com/smartystreets/assertions latest
go: finding github.com/gopherjs/gopherjs latest
go: finding github.com/smartystreets/goconvey latest
go: finding github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1
go: finding golang.org/x/sys latest
go: finding golang.org/x/tools v0.0.0-20190328211700-ab21143f2384
go: gopkg.in/DATA-DOG/[email protected]: go.mod has non-....v1 module path "github.com/DATA-DOG/go-sqlmock" at revision v1.3.3
go get: error loading module requirements

Not sure what is going on here? get the same result if I do

GO111MODULE=on go get -u github.com/junegunn/fzf

like image 224
Gert Cuykens Avatar asked Mar 30 '19 09:03

Gert Cuykens


1 Answers

Package github.com/gdamore/tcell which is required by fzf has gopkg.in/DATA-DOG/go-sqlmock.v1 dependency. In version 1.3.3 of go-sqlmock they started to use go modules without version suffix and now explicit indication of the version no more working.

go get gopkg.in/DATA-DOG/go-sqlmock.v1
go: gopkg.in/DATA-DOG/[email protected]: go.mod has non-....v1 module path "github.com/DATA-DOG/go-sqlmock" at revision v1.3.3
go: error loading module requirements

If you want to work on the devel package without updating its dependencies use go get github.com/junegunn/fzf without -u flag.

There is open pull request in tcell repository about this issue: https://github.com/gdamore/tcell/pull/267

like image 155
Vadim Ashikhman Avatar answered Oct 12 '22 06:10

Vadim Ashikhman