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: use quiet flag to allow tool integrations with Go modules #26628

marwan-at-work opened this issue Jul 26, 2018 · 4 comments


None yet
4 participants
Copy link

commented Jul 26, 2018

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

Tip - Darwin

What did you do?

go list -m -versions -json to list all the available upstream versions

What did you expect to see?

I'd like to only get the JSON output and not mod-fetching output.
The boolean QuietLookup in modfetch/cache.go is not being set anywhere which is causing the following to show

What did you see instead?

go: finding v0.8.0
	"Path": "",
	"Version": "v0.8.0",
	"Versions": [
	"Time": "2016-09-29T01:48:01Z"

This comment has been minimized.

Copy link

commented Jul 28, 2018

I think "go list -m" always need QuietLookup = true, maybe we don't need a quiet flag.


This comment has been minimized.

Copy link

commented Jul 31, 2018

Please can you confirm the full env details here (you've abbreviated the template) - what commit were you using etc?

I can't reproduce the issue you're seeing based on the steps above either.

In any case, stdout should always contain valid JSON, per #26218 (comment)


This comment has been minimized.

Copy link
Contributor Author

commented Jul 31, 2018

@myitcv I believe I was parsing both stderr and stdout, so I'll try again with just stdout and it should probably work. That being said, maybe the CL is still ok to have control over the QuietLookup variable in cache. Otherwise, using stdout is fine for my usecase. Thanks

@ianlancetaylor ianlancetaylor added this to the Go1.12 milestone Aug 3, 2018


This comment has been minimized.

Copy link

commented Aug 7, 2018

@marwan-at-work - I'm going to close per #26628 (comment), but please shout if you're seeing behaviour contrary to #26218 (comment)

@myitcv myitcv closed this Aug 7, 2018

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.