-
Notifications
You must be signed in to change notification settings - Fork 18k
cmd/go: 'go list -m -json' in an empty directory returns cryptic output #30136
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
This output is correct, if a bit strange: if you run a I suppose that we could add some sort of special case, but I can't think of one would simplify this case more than it complicates others. Any concrete suggestions? (CC @jayconrod) |
Without -m, the error message is more comprehensive. $ GO111MODULE=on go list -json go: cannot find main module; see 'go help modules' |
Is there anything There's a branch in |
|
True, so is So if we added a special case for this, it would just be for @hyangah WDYT? Worth adding? |
Depending on the outcome of #32027, this issue may become moot. |
Change https://go.dev/cl/585055 mentions this issue: |
@gabyhelp we need your help |
Is this still confusing people? |
The text was updated successfully, but these errors were encountered: