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

go1.12 got error parsing go.mod: unexpected module path "github.com/HdrHistogram/hdrhistogram-go" #30

Closed
wangzz719 opened this issue Sep 20, 2020 · 5 comments

Comments

@wangzz719
Copy link

This MR bb05e18 changed module path, while using go mod in go1.12 occurs this error:

go: github.com/codahale/[email protected]: parsing go.mod: unexpected module path "github.com/HdrHistogram/hdrhistogram-go"

@ahothan
Copy link
Collaborator

ahothan commented Sep 20, 2020

Hi, the original repository has been moved to a new github location, please update your src directory accordingly (you need to remove the old clone and issue another get from the new location).

@mammothbane
Copy link

mammothbane commented Sep 21, 2020

Edit: This problem seems to have just gone away in my env. See my comment below.

This rename has caused transitive dependency issues. Any module that depended on the old codahale/hdrhistogram-go (directly or not) is now broken and needs to update.

For instance, jaegertracing/jaeger-client-go depends on jaegertracing/jaeger-lib, which depends on hdrhistogram in this testing code (using the old codahale name).

The import in that file now breaks go mod because of the issue described in the OP -- the codahale version of the package can no longer be resolved, retroactive to all previously-published versions of this package. This is a breakage for everyone who depends on jaeger-client-go.

To resolve my problem in particular, I plan to PR the name change into jaeger-lib ASAP.

However, in case others aren't in direct control of their dependency on this module and are looking for a solution, you can use a replace directive in your go.mod, e.g.:

$ go mod edit -replace github.com/codahale/hdrhistogram=github.com/HdrHistogram/[email protected]

@wangzz719
Copy link
Author

I will have a try. Thanks!

@filipecosta90
Copy link
Collaborator

For instance, jaegertracing/jaeger-client-go depends on jaegertracing/jaeger-lib, which depends on hdrhistogram in this testing code (using the old codahale name).

@mammothbane please check if this PR will fix the issue on jaeger-lib jaegertracing/jaeger-lib#82
Also opening another one to fix jaeger-client-go

@mammothbane
Copy link

mammothbane commented Sep 23, 2020

@filipecosta90 Thanks for doing this — and I'm sorry I didn't update my comment, but this has stopped breaking for me.

I was fighting this for about 6 hours on Monday and I started making a PR into jaeger-lib myself, but on Tuesday morning, the issue spontaneously went away and I've been able to build again without any problems since. I have no idea what changed — it very consistently didn't work on previously — but I can't make it happen anymore.

If you're experiencing the problem, sorry, but I can no longer test a fix.

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

4 participants