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

can not use go mod with v4.1.0 #121

Closed
romapres2010 opened this issue Sep 28, 2019 · 2 comments
Closed

can not use go mod with v4.1.0 #121

romapres2010 opened this issue Sep 28, 2019 · 2 comments

Comments

@romapres2010
Copy link

I have a problem use go mod with v4.1.0.

First I try go mod tidy.
But got only v3.0.0
go: extracting github.com/ibm-messaging/mq-golang v3.0.0+incompatible

Then I edit go mod an replace
github.com/ibm-messaging/mq-golang v3.0.0+incompatible
to
github.com/ibm-messaging/mq-golang/v4 v4.1.0+incompatible

And try go mod tidy again
I got an error
go: github.com/ibm-messaging/mq-golang/[email protected]+incompatible: go.mod has non-.../v4 module path "github.com/ibm-messaging/mq-golang" (and .../v4/go.mod does not exist) at revision v4.1.0

@ibmmqmet ibmmqmet mentioned this issue Oct 7, 2019
@ibmmqmet
Copy link
Collaborator

ibmmqmet commented Oct 9, 2019

The whole area of Go modules when the tagged version is already greater than 2.0.0 seems problematic. See for example golang/go#25967 (comment) , golang/go#34217 or golang/go#31543

In particular, it seems that adding the new module capabilities are now considered a breaking change because of changes to the import path and would therefore require a new major number for this repository.

I think the best thing to do right now is ignore the module option until

  • the Go tooling has been improved and stabilised (some things appear to be suggested for Go 14)
  • older versions of Go that don't understand modules are old enough that they are not in general use
  • there are other API changes that could deserve a major semver change

@romapres2010
Copy link
Author

I can not ignore module, but I have found workaround.

go get github.com/ibm-messaging/mq-golang/ibmmq@19b946c

After that in in .mod file appeared
github.com/ibm-messaging/mq-golang v1.0.1-0.20190820103725-19b946c185a8

For now that is works well for me.

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

No branches or pull requests

2 participants