-
Notifications
You must be signed in to change notification settings - Fork 110
Compile error: parse.go:248:77: undefined sqlparser.SCHEMAS #826
Comments
I cannot reproduce this error. Can you share the steps you went through to get this error? Are all go-mysql-server dependencies up to date in your vendor folder as well? |
@erizocosmico I created an environment to reproduce. |
It's because dep is getting the latest vitess version, which has missing things go-mysql-server needs. go-mysql-server uses go modules to manage dependencies, so using go modules should make the problem go away. |
I see. Thank you. |
@erizocosmico I know this issue is closed but maybe you can help me out. I'm using $ mkdir x && cd x
$ go mod init github.com/bombsimon/x
go: creating new go.mod: module github.com/bombsimon/x
$ go get github.com/src-d/go-mysql-server
go get: github.com/src-d/go-mysql-server@v0.5.1: parsing go.mod:
module declares its path as: gopkg.in/src-d/go-mysql-server.v0
but was required as: github.com/src-d/go-mysql-server
# Explicit version
$ go get github.com/src-d/go-mysql-server@v0.5.1
go: finding github.com/src-d v0.5.1
go: finding github.com v0.5.1
go get: github.com/src-d/go-mysql-server@v0.5.1: parsing go.mod:
module declares its path as: gopkg.in/src-d/go-mysql-server.v0
but was required as: github.com/src-d/go-mysql-server
# Or older version
go get github.com/src-d/go-mysql-server@v0.4.0
go: finding github.com/src-d v0.4.0
go: finding github.com v0.4.0
go get: github.com/src-d/go-mysql-server@v0.4.0: parsing go.mod:
module declares its path as: gopkg.in/src-d/go-mysql-server.v0
but was required as: github.com/src-d/go-mysql-server Above output is with go1.13, same issue with go1.12 (but another error message). $ go1.12.10 get github.com/src-d/go-mysql-server
go: github.com/src-d/go-mysql-server@v0.5.1: parsing go.mod: unexpected module path "gopkg.in/src-d/go-mysql-server.v0"
go: error loading module requirements Seems to be working with other projects with go modules: $ go get github.com/sirupsen/logrus
go: downloading golang.org/x/sys v0.0.0-20190422165155-953cdadca894
go: extracting golang.org/x/sys v0.0.0-20190422165155-953cdadca894
go: finding golang.org/x/sys v0.0.0-20190422165155-953cdadca894
$ cat go.mod
module github.com/bombsimon/x
go 1.13
require github.com/sirupsen/logrus v1.4.2 // indirect Any advice? |
@bombsimon oh, I see the last release is from before migrating from gopkg.in. In this case, use:
or any other commit hash to get a specific revision (that one is the master revision right now). I just asked the maintainer for a new version so this problem goes away without resorting to pinning a specific commit. |
@erizocosmico: Thank you so much! I've yet to fully understand some of those special cases regarding |
Incorporating current master branch into an external main.go file:
The text was updated successfully, but these errors were encountered: