I have an android project that include some .proto files. After BE updates I had need to add v2 director to the project for represent version 2 of the proto files.
My proto files;
- v1/registration_update.proto
- v1/onsite_message.proto
- v1/custom_answer.proto
- v2/registration_update.proto
v1 files starts with syntax = “proto3”; package v1;
v2 files starts with syntax = “proto3”; package v2;
v1/registration_update imports v1/custom_answer.proto
v2/registration_update imports v1/custom_answer.proto
v1/onsite_message imports both v1/registration_update.proto, v2/registration_update.proto
So after that I am getting this error;
Cause: packages form a cycle:
onsite.v1 imports onsite.v2
v1/onsite_message.proto:
import "v2/registration_updated.proto";
onsite.v2 imports onsite.v1
v2/registration_updated.proto:
import "v1/custom_answer.proto";
Did anybody face this issue before? How can we fix it? Thanks in advance.
Here is my directory stack;