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/compile: internal compiler error: conflicting package heights 21 and 11 for path "github.com/golang/protobuf/proto" #39061

Closed
fwhezfwhez opened this issue May 14, 2020 · 9 comments
Labels
FrozenDueToAge WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.

Comments

@fwhezfwhez
Copy link

-go 1.12.17 win64

refer to golang/protobuf#1128

They said error might ocurred due to go tool chain.

How to fix it?

@ianlancetaylor
Copy link
Contributor

I can't recreate the problem using Go 1.12.

What is the exact command that you run? What is the exact output?

@ianlancetaylor ianlancetaylor added the WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. label May 14, 2020
@ALTree ALTree changed the title [Bug Report]internal compiler error: conflicting package heights 21 and 11 for path "github.com/golang/protobuf/proto" cmd/compile: internal compiler error: conflicting package heights 21 and 11 for path "github.com/golang/protobuf/proto" May 14, 2020
@ALTree
Copy link
Member

ALTree commented May 14, 2020

Are you invoking the compiler with -I? If yes, you may be triggering #25635.

@fwhezfwhez
Copy link
Author

I can't recreate the problem using Go 1.12.

What is the exact command that you run? What is the exact output?

go run main.go
go build

they all faces the same error internal compiler error: conflicting package heights 21 and 11 for path "github.com/golang/protobuf/proto"

@fwhezfwhez
Copy link
Author

@ianlancetaylor @ALTree
Here is my detail

go build -a -x

compile.log

@ianlancetaylor
Copy link
Contributor

Can you show us the input file that you are compiling? Thanks.

@fwhezfwhez
Copy link
Author

I kinda know why this error occurs.

My project uses binary-only package, the sourcr file x.a is built in manager's computer and then copy to mine.
x package imports github.com/golang/protobuf/proto whose version differs between manager'computer and mine and thus makes my project not builtable while importing x.a.

Basiclly I think proto's upgrading work has something conflict to the old commits.

@fwhezfwhez
Copy link
Author

I kinda know why this error occurs.

My project uses binary-only package, the sourcr file x.a is built in manager's computer and then copy to mine.
x package imports github.com/golang/protobuf/proto whose version differs between manager'computer and mine and thus makes my project not builtable while importing x.a.

Basiclly I think proto's upgrading work has something conflict to the old commits.

But still confused, If proto repo didn't upgrade well, The error should print like:

function XXXX not found
YYY undefine

However it print compile error. Ok, go back to go tool chain, I'm trying to reproduce bug spot anyway.

@ianlancetaylor
Copy link
Contributor

Note that Go 1.12 is the last release that supported binary-only packages, and that Go 1.12 is no longer supported.

@fwhezfwhez
Copy link
Author

Sorry that I don't have source file to locate what causes this problem. I try to rebuild a minimum problem case but fail.All things run ok.

That's it! I'll use protobuf package of old and fixed version to avoid this compile error.

@golang golang locked and limited conversation to collaborators May 22, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.
Projects
None yet
Development

No branches or pull requests

4 participants