rhysd / notes-cli

Small markdown note taking CLI app playing nicely with your favorite editor and other CLI tools
MIT License
218 stars 26 forks source link

'go get' fails at google/go-github/v30/github #11

Closed MatthewCroughan closed 4 years ago

MatthewCroughan commented 4 years ago
matthew@thinkpad ~/git $ go get -u github.com/rhysd/notes-cli
package github.com/google/go-github/v30/github: cannot find package "github.com/google/go-github/v30/github" in any of:
    /usr/lib/go/src/github.com/google/go-github/v30/github (from $GOROOT)
    /home/matthew/go/src/github.com/google/go-github/v30/github (from $GOPATH)

Unsure if this is to do with my gopath, etc.

MatthewCroughan commented 4 years ago

here's a verbose output:

matthew@thinkpad ~/git $ go get -u -v github.com/rhysd/notes-cli
github.com/rhysd/notes-cli (download)
github.com/blang/semver (download)
github.com/fatih/color (download)
github.com/kballard/go-shellquote (download)
github.com/mattn/go-colorable (download)
github.com/mattn/go-isatty (download)
get "golang.org/x/sys/unix": found meta tag get.metaImport{Prefix:"golang.org/x/sys", VCS:"git", RepoRoot:"https://go.googlesource.com/sys"} at //golang.org/x/sys/unix?go-get=1
get "golang.org/x/sys/unix": verifying non-authoritative meta tag
golang.org/x/sys (download)
get "golang.org/x/sys/internal/unsafeheader": found meta tag get.metaImport{Prefix:"golang.org/x/sys", VCS:"git", RepoRoot:"https://go.googlesource.com/sys"} at //golang.org/x/sys/internal/unsafeheader?go-get=1
get "golang.org/x/sys/internal/unsafeheader": verifying non-authoritative meta tag
github.com/mattn/go-runewidth (download)
github.com/pkg/errors (download)
github.com/rhysd/go-github-selfupdate (download)
github.com/google/go-github (download)
package github.com/google/go-github/v30/github: cannot find package "github.com/google/go-github/v30/github" in any of:
    /usr/lib/go/src/github.com/google/go-github/v30/github (from $GOROOT)
    /home/matthew/go/src/github.com/google/go-github/v30/github (from $GOPATH)
github.com/inconshreveable/go-update (download)
github.com/tcnksm/go-gitconfig (download)
github.com/ulikunitz/xz (download)
get "golang.org/x/oauth2": found meta tag get.metaImport{Prefix:"golang.org/x/oauth2", VCS:"git", RepoRoot:"https://go.googlesource.com/oauth2"} at //golang.org/x/oauth2?go-get=1
golang.org/x/oauth2 (download)
get "golang.org/x/oauth2/internal": found meta tag get.metaImport{Prefix:"golang.org/x/oauth2", VCS:"git", RepoRoot:"https://go.googlesource.com/oauth2"} at //golang.org/x/oauth2/internal?go-get=1
get "golang.org/x/oauth2/internal": verifying non-authoritative meta tag
get "golang.org/x/net/context/ctxhttp": found meta tag get.metaImport{Prefix:"golang.org/x/net", VCS:"git", RepoRoot:"https://go.googlesource.com/net"} at //golang.org/x/net/context/ctxhttp?go-get=1
get "golang.org/x/net/context/ctxhttp": verifying non-authoritative meta tag
golang.org/x/net (download)
get "gopkg.in/alecthomas/kingpin.v2": found meta tag get.metaImport{Prefix:"gopkg.in/alecthomas/kingpin.v2", VCS:"git", RepoRoot:"https://gopkg.in/alecthomas/kingpin.v2"} at //gopkg.in/alecthomas/kingpin.v2?go-get=1
gopkg.in/alecthomas/kingpin.v2 (download)
github.com/alecthomas/template (download)
github.com/alecthomas/units (download)
MatthewCroughan commented 4 years ago

https://github.com/google/go-github/tree/master/github exists, but v30 does not exist any more. Maybe you're now supposed to use the master?

MatthewCroughan commented 4 years ago

I've made an issue here, assuming this is a genuine problem with upstream and would be interested to figure out why it is not, if it is not. https://github.com/google/go-github/issues/1570

MatthewCroughan commented 4 years ago

The CI shows the same failure here. https://travis-ci.org/github/rhysd/notes-cli/jobs/673803098

Comments from a user in IRC indicate that this is a misunderstanding of "modules mode"

GO111MODULE=on go get -u github.com/rhysd/notes-cli/cmd/notes for example works fine on my system.

MatthewCroughan commented 4 years ago

go env -w GO111MODULE=on will set module mode on for users. This should be included in the README to make sure that people can successfully install via go get.

MatthewCroughan commented 4 years ago

This is due to https://github.com/golang/go/issues/30515