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

x/tools/gopls: stderr printout in init() from asmdecl analyser #52646

Closed
leitzler opened this issue May 2, 2022 · 7 comments
Closed

x/tools/gopls: stderr printout in init() from asmdecl analyser #52646

leitzler opened this issue May 2, 2022 · 7 comments
Labels
FrozenDueToAge gopls Issues related to the Go language server, gopls. Tools This label describes issues relating to any tools in the x/tools repository.
Milestone

Comments

@leitzler
Copy link
Contributor

leitzler commented May 2, 2022

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

$ go version
go version devel go1.19-5ccd8e5133 Mon Mar 14 21:23:36 2022 +0000 linux/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
N/A

What did you do?

Run gopls

What did you expect to see?

No printouts to stderr.

What did you see instead?

A printout about unknown architecture from the init() func in asmdecl analyser introduced via https://go-review.googlesource.com/c/tools/+/356089.

This causes problems for govim integration tests as they include explicit checks that there are no stderr printouts.

$ gopls version
2022/05/02 07:46:20 unknown architecture loong64
golang.org/x/tools/gopls master
    golang.org/x/tools/gopls@v0.0.0-20220429180640-aaffface24dc h1:6KDUj6aD2FUVfGHl0PWu/cOrY/09l/ReO5wT7CQcIW8=
@gopherbot gopherbot added Tools This label describes issues relating to any tools in the x/tools repository. gopls Issues related to the Go language server, gopls. labels May 2, 2022
@gopherbot gopherbot added this to the Unreleased milestone May 2, 2022
@leitzler
Copy link
Contributor Author

leitzler commented May 2, 2022

//cc @findleyr

@findleyr
Copy link
Contributor

findleyr commented May 2, 2022

I believe this should have been fixed upstream in go/types by https://go.dev/cl/401576. Can you update your Go build to avoid the problem?

@suzmue suzmue added the WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. label May 2, 2022
@leitzler
Copy link
Contributor Author

leitzler commented May 2, 2022

Updating and rebuilding does in fact help, thanks!

In our CI we run against Go 1.17 & Go 1.18 so it won't really help us for older versions. I imagine that anything that imports asmdecl currently have the printout, right? (if it is built with a released Go version that is).

Would it be possible to guard it with a 1.19 build tag as workaround? I'm happy to mail a CL for it.

@findleyr findleyr removed the WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. label May 2, 2022
@findleyr
Copy link
Contributor

findleyr commented May 2, 2022

@leitzler yes you're right that we should guard the new arch in the asmdecl analyzer with a build tag. If you don't mind mailing a CL, that would be great! Please send to me and @XiaodongLoong

@findleyr findleyr modified the milestones: Unreleased, gopls/v0.8.4 May 2, 2022
@findleyr
Copy link
Contributor

findleyr commented May 2, 2022

@leitzler just let us know if you don't think you'll be getting to this. I'd like to fix it before the v0.8.4 release next week. Absolutely no worries if you'd rather we take care of it.

@gopherbot
Copy link

Change https://go.dev/cl/403874 mentions this issue: go/analysis/passes/asmdecl: add build tag for loong64

@XiaodongLoong
Copy link
Contributor

CC @golang/loong64

@golang golang locked and limited conversation to collaborators May 4, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge gopls Issues related to the Go language server, gopls. Tools This label describes issues relating to any tools in the x/tools repository.
Projects
None yet
Development

No branches or pull requests

5 participants