-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
gopkg import with the mocks subpackage #497
Comments
Hmm, cc @wvanbergen this is actually kind of annoying; if we switch the import paths for the mocks to use gopkg, then it will break for anybody using master directly (of which there are at least a few)... |
It might be possible to work around this via https://golang.org/doc/go1.4#canonicalimports? I'm not 100% sure, I think it depends on exactly how gopkg.in proxies the repo. |
/me suppresses rant about the shitty package management tooling in go. I don't know how that would work. Based on those docs, adding a canonical import path will just make one of the two locations fail. |
maybe we can just use a relative import? |
Relative imports break |
Unfortunately it seems like there is still no real solution to this issue yet. Here are my thoughts: Did you consider moving the mocks into the Of course this would break all users that import the github repository directly but if this is actually an issue for the library then I wonder why you are using |
I wonder if this is still an issue with go modules? |
Yes, I believe so @varun06 |
@bai since Sarama requires go modules for some time now, is there any benefit to still using gopkg.in anymore? Perhaps we should enable the canonical import path of github.com/Shopify/sarama everywhere? |
@dnwe I'm 👍for this change. |
Thank you for taking the time to raise this issue. However, it has not had any activity on it in the past 90 days and will be closed in 30 days if no updates occur. |
Closing this as outdated, please re-open if you still think there is something we can do here |
The
mocks
subpackage importsgithub.com/Shopify/sarama
. The README suggests usinggopkg.in
(which github.com/wvanbergen/kafka does), but it leads to conflicts when using mocks like so:The text was updated successfully, but these errors were encountered: