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";
packagemypackage; // this is the only change to the MWE from README.mdmessageEchoRequest {
stringvalue=1;
// Number of extra times to echouint32extra_times=2;
}
messageEchoResponse {
repeatedstringvalues=1;
}
messageEchoStreamResponse {
stringvalue=1;
}
serviceEcho {
rpcEcho(EchoRequest) returns (EchoResponse);
rpcEchoStream(EchoRequest) returns (streamEchoStreamResponse);
}
Hi, any plans on fixing this issue? Seems like there has been a fix (#436) for #438, which is a similar issue, but not sure if this one was also taken care of by the same PR.
Also, any plans for a new release or beta including the above fix? The current beta (2.0.0b5) seems to be 9 months old :)
Steps to reproduce
Install
betterproto-2.0.0b5
+ tooling:other versions:
Create an
example.proto
Create the directory
Generate Python Code:
python -m grpc_tools.protoc -I . --python_betterproto_out=lib example.proto
Check that
lib/mypackage/__init__.py
contains no unresolvable imports. ✔Up to here, this is just the MWE from
README.md
with a different but all-lower package name.Introduce Upper Case Letters in the Package Name
Now modify the above
example.proto
and change the all-lower casepackage mypackage
in line 3 to an UpperCamelpackage MyPackage
.Repeat the next steps up to the code generation (don't forget to clean up
lib
before re-generating).The newly generate
lib/MyPackage/__init__.py
now contains unresolvable imports:The
lib/__init__.py
does not contain anything to import.No classes
MyPackageEchoResponse
orMyPackageEchoStreamResponse
have been generated ❌Expected Behaviour
The code generation shall work for mixed casing package names.
The text was updated successfully, but these errors were encountered: