Skip to content

cmd/go: poor error message when running 'go mod download' on a path that can only be used if replaced #46496

Open
@marystern

Description

@marystern

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

$ go version
go version go1.16.4 linux/amd64

Does this issue reproduce with the latest release?

yes

What did you do?

As per a previous discussion (ref #37554 ), I'm using "_" as a domain for local packages. This used to work pre 1.16. It now seems to be broken as of 1.16?

go: _/xxx/[email protected]: missing go.sum entry; to add it:
	go mod download _/xxx/log

$ go mod download _/xxx/log
go: _/xxx/[email protected]: malformed module path "_/xxx/log": missing dot in first path element

.. I believe that this used to work fine?... :(

Is this an intentional break? If so, can you please re-visit #37554 and suggest a better way of working? (For what it's worth, it's becoming harder and harder to "just code" in Go due to these recent "improvements" in 1.16, or I'm simply making a silly mistake?).

Metadata

Metadata

Assignees

No one assigned

    Labels

    BadErrorMessageIssues related compiler error messages that should be better.GoCommandcmd/goNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.modules

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions