You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
syntax="proto3";
packagehelloThere;
// Greeting represents a message you can tell a user.messageGreeting {
stringmessage=1;
Modelmodel=2;
}
messageModel {
doublevalue=1;
}
creates python file
fromdataclassesimportdataclassimportbetterprotofrom .. importHelloThereModelas_HelloThereModel__@dataclass(eq=False, repr=False)classGreeting(betterproto.Message):
"""Greeting represents a message you can tell a user."""message: str=betterproto.string_field(1)
model: "_HelloThereModel__"=betterproto.message_field(2)
@dataclass(eq=False, repr=False)classModel(betterproto.Message):
value: float=betterproto.double_field(1)
Which does not work due to some relative imports
If you fix package name helloThere -> hello_there it work ok
The text was updated successfully, but these errors were encountered:
Compiling proto like this
creates python file
Which does not work due to some relative imports
If you fix package name
helloThere
->hello_there
it work okThe text was updated successfully, but these errors were encountered: