Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broken go.mod #86

Closed
rkuska opened this issue Apr 30, 2019 · 7 comments
Closed

Broken go.mod #86

rkuska opened this issue Apr 30, 2019 · 7 comments
Labels

Comments

@rkuska
Copy link

rkuska commented Apr 30, 2019

It looks like this commit broke the go.mod file:

0b4f1fc

Latest working version that I can update to and go mod tidy goes through is 5.1.1, 5.1.2 fails with following message:

go: github.com/caarlos0/env@v5.1.2+incompatible: go.mod has post-v5 module path "github.com/caarlos0/env/v5" at revision v5.1.2

caarlos0/env is listed as github.com/caarlos0/env v5.1.1+incompatible in my go.mod file (upgrading from v4).

@caarlos0
Copy link
Owner

caarlos0 commented Apr 30, 2019

you need to change the import to github.com/caarlos0/env/v5, unfortunately that's how go modules work...

more info: https://github.com/golang/go/wiki/Modules#releasing-modules-v2-or-higher

GitHub
The Go programming language. Contribute to golang/go development by creating an account on GitHub.

@rkuska
Copy link
Author

rkuska commented Apr 30, 2019

Interesting, I thought it is needed to specify major version in import only if you use multiple such versions.

@caarlos0
Copy link
Owner

Interesting, I thought it is needed to specify major version in import only if you use multiple such versions.

yeah, seems like not... anything greater than v1 needs that.

I particularly don't like it very much, but 🤷‍♂️

@caarlos0
Copy link
Owner

caarlos0 commented Apr 30, 2019

I actually already added it to docs: https://github.com/caarlos0/env#go-modules

GitHub
Simple lib to parse envs to structs. Contribute to caarlos0/env development by creating an account on GitHub.

@rkuska
Copy link
Author

rkuska commented Apr 30, 2019

Didn't notice that one, sorry! Thank you and sorry for the false issue, closing this :-)

@rkuska rkuska closed this as completed Apr 30, 2019
@caarlos0
Copy link
Owner

no problem, thanks! :D

@caarlos0
Copy link
Owner

caarlos0 commented May 15, 2019

btw: fixed on https://github.com/caarlos0/env/releases/tag/v6.0.0

GitHub
Simple lib to parse envs to structs. Contribute to caarlos0/env development by creating an account on GitHub.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants