-
Notifications
You must be signed in to change notification settings - Fork 18k
cmd/go: compilation fails with replace with repository module #32389
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
Comments
Thanks for accepting! |
@av86743 the first error reported here:
might be an instance of #29268 (comment). Does that seem related to the first error you reported here? Aside from that, can you expand a bit on what you are attempting to do here? For example, you say:
Could you expand on why you are using a repository that does not exist? For example, is this a simplified example of something else you saw? |
Irrelevant, disregard this. It is just statement of a fact, it's not even tagged as an error.
I am giving you a straight example where go.mod "replace" directive does not work. And registering your response.
This is to bring your attention to the fact that compiler's error message reports a type from repository which does not even exist. How much sense does it make to you?
Whether that repository exists or not, is immaterial - in the presence of "replace" directive for this repository. Don't you agree? |
The When you With the current semantics of We know that there is a use-case for |
Duplicate of #26904 |
What do mean by saying "...it must use..." etc etc? |
You could simply say: "@rsc solved it in https://golang.org/cl/174939 ." Thanks, in any case. Cox rocks. Which also rhymes. Niccce, whichever way you look at it. |
Note that CL 174939 isn't merged (and won't be for 1.13). There are some remaining issues with replacement semantics that we need to work out (described in a comment on the CL), and I'm planning to make another run at it for 1.14. |
I've backported that CL (plus related changesets) to go1.12.5. It looks all right so far, but I need more time to validate typical use cases, review 5 items from CL which you mentioned, and just cool down a bit before I publish the port. |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Sure, why not?
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
What did you expect to see?
Compilation does not fail, at least. See 'inner/inner.go' for a variant with imports replaced manually, which compiles.
What did you see instead?
Oh, come on now. Repository 'github.com/av86743/go-leveldb' does not even exist. Are you sure you know what you are talking about?
The text was updated successfully, but these errors were encountered: