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

cmd/go: go mod edit -replace does not accept a module path without a dot #30513

Open
neclepsio opened this Issue Mar 1, 2019 · 2 comments

Comments

Projects
None yet
3 participants
@neclepsio
Copy link

neclepsio commented Mar 1, 2019

What version of Go are you using (go version)?

$ go version
go version go1.12 windows/amd64

Does this issue reproduce with the latest release?

Yes.

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
set GOARCH=amd64
set GOBIN=
set GOEXE=.exe
set GOFLAGS=
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOOS=windows
set GOPROXY=
set GORACE=
set GOTMPDIR=

What did you do?

go mod edit -replace=foo=bar

What did you expect to see?

Adding a replace into go.mod, since if it is added manually there is no problem.

What did you see instead?

go mod: -replace=foo=bar: invalid old path: malformed module path "foo": missing dot in first path element

@bradfitz bradfitz changed the title go mod edit -replace does not accept a module path without a dot cmd/go: go mod edit -replace does not accept a module path without a dot Mar 1, 2019

@bradfitz

This comment has been minimized.

Copy link
Member

bradfitz commented Mar 1, 2019

/cc @bcmills

@bradfitz bradfitz added this to the Go1.13 milestone Mar 1, 2019

@bcmills

This comment has been minimized.

Copy link
Member

bcmills commented Mar 14, 2019

This is somewhat related to #28439, in that we're over-validating inputs to mod edit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.