Pr0Ger/protobuf3

compile fail when using package at protobuf

Opened this issue · 1 comments

I use:

package data_base_msg;

in my message define file A, and message define file B include A

when compile, it give me error:
Traceback (most recent call last):
File "/usr/local/bin/protoc-gen-python3", line 44, in
compiler = Compiler(desc_map[file_name], top_level_elements)
File "/usr/local/lib/python3.6/site-packages/protobuf3/compiler/init.py", line 54, in init
self.process_message(message)
File "/usr/local/lib/python3.6/site-packages/protobuf3/compiler/init.py", line 104, in process_message
self.process_field(message.name, field, embedded)
File "/usr/local/lib/python3.6/site-packages/protobuf3/compiler/init.py", line 148, in process_field
file_to_import = splitext(self.__tle_map[top_level_name])[0].replace('/', '.')
KeyError: 'data_base_msg'
--python3_out: protoc-gen-python3: Plugin failed with status code 1.

Hi! Have anyone resolved this issue?
I'am having the same kind of trouble and could not figure it out just yet.