Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use protoc mypy plugin to generate type stubs #62

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

ldorigo
Copy link

@ldorigo ldorigo commented Dec 7, 2022

This makes the developer experience much nicer for people using static type checkers (mypy of pylance). Addresses my comment in #54 .

Note that the makefile failed for me, I had to change grpc_python_out to python_grpc_out - not sure why? Maybe the name changed in a recent version of grpcio.

@ldorigo
Copy link
Author

ldorigo commented Dec 7, 2022

It's unclear why there are so many new files - maybe not everything in /src has to be included in git?

@ldorigo
Copy link
Author

ldorigo commented Dec 7, 2022

It looks like grpc-generated files are called xxx_grpc rather than _pb2_grpc. Probably the original files were generated as protobuf 2, which is now replaced?

@ldorigo
Copy link
Author

ldorigo commented Dec 7, 2022

I removed the extra files, please check this is correct

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant