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

Multiple package definitions. #33

Closed
magick93 opened this issue Sep 30, 2017 · 2 comments
Closed

Multiple package definitions. #33

magick93 opened this issue Sep 30, 2017 · 2 comments

Comments

@magick93
Copy link

magick93 commented Sep 30, 2017

Am trying to generate java classes from protoc files, and get this error:

Multiple package definitions.

The proto file looks like:

syntax = "proto3";	
option java_package = "io.myco.message";
package myco;	
message UserRecordUpdateResponseMessage {

int32 int = 1;
}

From my understanding the protoc file is valid.

@sergei-ivanov
Copy link
Member

This is not a maven plugin error, it is a protoc error. Have you tried compiling your proto file with a command line protoc? I wonder if the error is going to go away if you put the package instruction before the option java_package?

@magick93
Copy link
Author

magick93 commented Oct 3, 2017

I didnt try changing the order. I instead removed the java_package statement, and the error is now gone.

@magick93 magick93 closed this as completed Oct 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants