Open TamirFriedman-RecoLabs opened 2 years ago
Hi, sorry about this could you perhaps attach the file that causes this error?
Given that I removed mutable_default_args this might work after https://github.com/danielgtaylor/python-betterproto/pull/311
@TamirFriedman-RecoLabs if you want to try the efokschaner:methods-take-messages branch to find out it would help.
The error is caused by embedded enums. I have a similar error, here's a minimal reproducer:
syntax = "proto3";
package test;
message Msg {
enum InnerEnum {
ENUM_ZERO = 0;
ENUM_ONE = 1;
}
InnerEnum en = 1;
}
message MsgReply {}
service Service {
rpc Method(Msg) returns (MsgReply);
}
Moving InnerEnum outside msg stops the error from occuring. I suspect the issue is due to the new support for open enums.
This appears to be fixed by d260f071e01657287888e15b73623305b56b4d9f somehow
The error is caused by embedded enums. I have a similar error, here's a minimal reproducer:
syntax = "proto3"; package test; message Msg { enum InnerEnum { ENUM_ZERO = 0; ENUM_ONE = 1; } InnerEnum en = 1; } message MsgReply {} service Service { rpc Method(Msg) returns (MsgReply); }
Moving InnerEnum outside msg stops the error from occuring. I suspect the issue is due to the new support for open enums.
I'll add a few tests so that issues like this don't happen again
Usage fails with BetterProto 2.0.0b4 Version
Replacing to older version
Usage succeed with BetterProto 2.0.0b3 Version