rubenv / sql-migrate

SQL schema migration tool for Go.
MIT License
3.18k stars 270 forks source link

install error #176

Open GitSumito opened 4 years ago

GitSumito commented 4 years ago

When I try to install this tool, I encounter below error.

% go get -v github.com/rubenv/sql-migrate/...
github.com/hashicorp/go-multierror
github.com/mattn/go-sqlite3
# github.com/hashicorp/go-multierror
../../../github.com/hashicorp/go-multierror/multierror.go:112:9: undefined: errors.As
../../../github.com/hashicorp/go-multierror/multierror.go:117:9: undefined: errors.Is

my environmet is this

go version go1.11 darwin/amd64

Does anyone have tips to solve this problem?

ydanilin commented 4 years ago

Take the latest version of Go.
I tried with 1.10.3 and 1.11 - exactly this error . With 1.14.3 it installs successfully.

yihau commented 4 years ago

The go-mutierror use the errors.As and errors.Is I think your go version should be bigger than 1.13

hongminhcbg commented 4 years ago

@ydanilin I use go go1.14.4 linux/amd64 but i can't install success my version: go version go1.14.4 linux/amd64

my error:

go: downloading github.com/rubenv/sql-migrate v0.0.0-20180704111356-ba2c6a7295c59448dbc195cef2f41df5163b3892
go: github.com/rubenv/sql-migrate@v0.0.0-20180704111356-ba2c6a7295c59448dbc195cef2f41df5163b3892: invalid pseudo-version: revision is longer than canonical (ba2c6a7295c5)
dtlares commented 4 years ago

I had the same error, but finally it is working with go version go1.13.3 linux/amd64.

alhamsya commented 2 years ago

you can try : go get -v github.com/rubenv/sql-migrate/...@f842348935589e4563be545226d465178bd439cf