go: go mod doesn't work for github.com/gomarkdown/markdown/html
What version of Go are you using (go version
)?
$ go version go version go1.11 darwin/amd64
Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (go env
)?
OS X 10.13.6
$ go env GOARCH=“amd64” GOBIN=“” GOCACHE=“/Users/kjk/Library/Caches/go-build” GOEXE=“” GOFLAGS=“” GOHOSTARCH=“amd64” GOHOSTOS=“darwin” GOOS=“darwin” GOPATH=“/Users/kjk/src/go” GOPROXY=“” GORACE=“” GOROOT=“/usr/local/Cellar/go/1.11/libexec” GOTMPDIR=“” GOTOOLDIR=“/usr/local/Cellar/go/1.11/libexec/pkg/tool/darwin_amd64” GCCGO=“gccgo” CC=“clang” CXX=“clang++” CGO_ENABLED=“1” GOMOD=“” CGO_CFLAGS=“-g -O2” CGO_CPPFLAGS=“” CGO_CXXFLAGS=“-g -O2” CGO_FFLAGS=“-g -O2” CGO_LDFLAGS=“-g -O2” PKG_CONFIG=“pkg-config” GOGCCFLAGS=“-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/2k/p2_4052s70vd5_cfdm0k0l740000gn/T/go-build479826685=/tmp/go-build -gno-record-gcc-switches -fno-common”
What did you do?
- make sure you’re OUTSIDE OF GOPATH
git clone https://github.com/kjk/modtest.git
cd modtest
go mod init github.com/kjk/modtest
go build
What did you expect to see?
This should build.
What did you see instead?
$ go build
go: finding github.com/gomarkdown/markdown/ast latest
go: finding github.com/gomarkdown/markdown/html latest
go: finding github.com/gomarkdown/markdown latest
main.go:8:2: unknown import path "github.com/gomarkdown/markdown/html": cannot find module providing package github.com/gomarkdown/markdown/html
For some reason go mod
has issue with github.com/gomarkdown/markdown/html
even though it works for github.com/gomarkdown/markdown
and github.com/gomarkdown/markdown/ast
.
The source of the problem seems to be:
$ go get -v github.com/gomarkdown/markdown/html
go: finding github.com/gomarkdown/markdown/html latest
go: finding github.com/gomarkdown/markdown latest
Fetching https://github.com?go-get=1
Parsing meta tags from https://github.com?go-get=1 (status code 200)
go get github.com/gomarkdown/markdown/html: no matching versions for query "latest"
There is no problem when running same go get
when in GOPATH
.
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 17 (10 by maintainers)
Yeah,
go clean
needs quite a bit of work for 1.12. (See also #27469, #27458, #27310, and #26991.)That could certainly do it.
go1.11beta2
was a pretty rough build for modules (sorry about that!).