-
Notifications
You must be signed in to change notification settings - Fork 492
Unexpected module path #436
Comments
I have just noticed this too, seem the |
@heschik Oh I was looking at this very issue just now.. It seems that somehow golang.org/x/lint is being imported by someone as github.com/golang/lint (its former import path). golang.org/x/lint now has a "//import" comment, so it shouldn't even build with that import path. I saw this in x/exp. I'm wondering if you can share which module you're seeing this in |
Hi, I'm also seeing this error. I'm trying to generate a go.mod file for a project I'm working on. However it is failing with:
We don't directly depend on the golang linter, so not certain how I can get beyond this issue. |
I see the same thing, and grep-ing from my old vendor folder I have no imports matching that. Trying to move https://github.com/alde/ale from glide to mod |
@dmitshur to see if he has ideas |
I'm seeing this as well, let me know if I can provide any additional debug info. For now here is my require list from go.mod:
|
I can reproduce this in an empty module, using Go 1.12:
|
For those who are running into this, are you running |
I'm running |
14:41:03$ golint -set_exit_status -min_confidence 0.81 ./pkg/...
-bash: golint: command not found
14:41:11$ go get golang.org/x/lint/golint
go: finding golang.org/x/lint/golint latest
go: finding golang.org/x/lint latest
14:41:19$ golint -set_exit_status -min_confidence 0.81 ./pkg/...
14:41:48$ rm -rf ~/go/src/golang.org/x/lint/ ~/go/bin/golint
14:41:56$ golint -set_exit_status -min_confidence 0.81 ./pkg/...
-bash: /Users/svilgelm/go/bin/golint: No such file or directory
14:41:59$ go get -u golang.org/x/lint/golint
go: finding golang.org/x/lint/golint latest
go: finding golang.org/x/lint latest
go: finding golang.org/x/sync latest
go: finding golang.org/x/net latest
go: finding golang.org/x/tools latest
go: finding google.golang.org/genproto latest
go: finding github.com/golang/glog latest
go: finding github.com/golang/lint latest
go: github.com/golang/[email protected]: parsing go.mod: unexpected module path "golang.org/x/lint"
go: finding honnef.co/go/tools latest
go: finding golang.org/x/exp latest
go: finding golang.org/x/oauth2 latest
go: finding golang.org/x/sys latest
go get: error loading module requirements
14:42:17$ golint -set_exit_status -min_confidence 0.81 ./pkg/...
-bash: /Users/svilgelm/go/bin/golint: No such file or directory |
In a clean docker build I see a failure on an empty module w/ with -u
without -u
|
Signed-off-by: Prativa Bawri<[email protected]>
@bcmills: any ideas? |
We're going to look into whether we can figure out what's going on. If we can't find any leads in a couple of days, we'll revert the change that added the go.mod file. But hopefully we don't need to. |
FWIW this bug actually made me check myself on the copy/paste of Let me know if there is any additional debugging I can do or information I can provide. |
Looks like it's fixed: googleapis/go-genproto#144.. sorry too soon :) |
Appending the current result of @kpurdon docker command. It has become much much longer in the past 2 hours. That looks awfully like a circle-import of grand scheme.
This awfully reminds me of that Sirupsen business (sirupsen/logrus#566 and sirupsen/logrus#570) a few years back... |
for the if fails when I use -u, without -u it works fine |
* Adding more unit tests for the sdk and some refactoring - Added more tests in the sdk - Removed some logs that are not required. - Removed a duplicate function * Updating go.sum to fix the build failure * Fix build error as reported in golang/lint#436 Signed-off-by: Prativa Bawri<[email protected]>
From a quick look just now, there might be two issues, where Create a clean module cache, and do a
grep our newly populated module cache:
where the
edit: direct user of the old |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Let's take a look at seemingly problematic
The grpc
|
FWIW, Go 1.11.5 fails with similar error:
which fails with:
|
Thanks for the nice analysis @thepudds. It was a good idea to clean the module cache, run the Independent of the lint issue, I've filed golang/go#30455 for the I think I see the root cause of The problem is in the https://github.com/openzipkin/zipkin-go module. Its latest tagged version is v0.1.5, which requires the bad old grpc module you mentioned: https://github.com/openzipkin/zipkin-go/blob/v0.1.5/go.mod#L27 I'll file an issue into that repo. As soon as they issue a new version that updates its grpc dependency, I believe the |
@broady Thanks, filed golang/go#30833 for that. |
Link: golang/lint#436 Error while building: go: github.com/golang/[email protected]: parsing go.mod: unexpected module path "golang.org/x/lint"
Update: I just realized that what I'm saying here, is the same as what @broady said above at #436 (comment) I just ran into this issue trying to upgrade an existing project with
I'm not completely sure what happened here, but it seemed the only link from my project to lint was through grpc, where version 1.16.0 references the github.com/golang/lint url (though it also references golang.org/x/lint). Some of my dependencies again depended on grpc 1.16.0, which is probably why that was pulled in. However, the latest version of grpc has this fixed, which I would expect to be considered when I run I tried explicitly upgrading grpc first and then doing a What did work, was to add this to my
Then running I suspect that this is a go bug, and it occurs as long as any of your dependencies explictly list grpc v1.16.0 (even though you've upgraded to a later version in your own go.mod) and might go away when everbody lists newer grpc versions. I haven't properly verified this, though. |
This change updates just github.com/denisenkom/go-mssqldb to latest to resolve the mess caused by golang/lint adding mod support. See golang/lint#436.
This change updates just github.com/denisenkom/go-mssqldb to latest to resolve the mess caused by golang/lint adding mod support. See golang/lint#436.
One of the Ankh dependencies is importing `github.com/golang/lint` which now specifies it must be imported as `golang.org/x/lint`. ```sh go mod edit -replace github.com/golang/lint@latest=golang.org/x/lint@latest ``` golang/go#30831 golang/lint#436
Unable to fetch
golang/lint
because of unexpected module path error.The text was updated successfully, but these errors were encountered: