-
Notifications
You must be signed in to change notification settings - Fork 49
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
Add python message generation #355
Conversation
Signed-off-by: Addisu Z. Taddese <[email protected]>
Codecov Report
@@ Coverage Diff @@
## main #355 +/- ##
=======================================
Coverage 96.89% 96.89%
=======================================
Files 28 28
Lines 1064 1064
=======================================
Hits 1031 1031
Misses 33 33 |
# GENERATE_PYTHON - generates python code for the message if specified | ||
# One value arguments: | ||
# MSGS_GEN_SCRIPT - Path to the message generation python script | ||
# PROTO_PACKAGE - Protobuf package the file belongs to (e.g. "gz.msgs") | ||
# PROTOC_EXEC - Path to protoc | ||
# GZ_PROTOC_PLUGIN - Path to the gazebo-specific protobuf compiler executable | ||
# INPUT_PROTO - Path to the input .proto file | ||
# OUTPUT_CPP_DIR - Path where C++ files are saved | ||
# OUTPUT_PYTHON_DIR - Path where Python files are saved | ||
# OUTPUT_INCLUDES - A CMake variable name containing a list that the C++ header path should be appended to | ||
# OUTPUT_CPP_HH_VAR - A CMake variable name containing a list generated headers should be appended to | ||
# OUTPUT_DETAIL_CPP_HH_VAR - A CMake variable name containing a list that the C++ detail headers should be appended to | ||
# OUTPUT_CPP_CC_VAR - A Cmake variable name containing a list that the C++ source files should be appended to | ||
# OUTPUT_PYTHON_VAR - A Cmake variable name containing a list that the python file should be appended to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# GENERATE_PYTHON - generates python code for the message if specified | |
# One value arguments: | |
# MSGS_GEN_SCRIPT - Path to the message generation python script | |
# PROTO_PACKAGE - Protobuf package the file belongs to (e.g. "gz.msgs") | |
# PROTOC_EXEC - Path to protoc | |
# GZ_PROTOC_PLUGIN - Path to the gazebo-specific protobuf compiler executable | |
# INPUT_PROTO - Path to the input .proto file | |
# OUTPUT_CPP_DIR - Path where C++ files are saved | |
# OUTPUT_PYTHON_DIR - Path where Python files are saved | |
# OUTPUT_INCLUDES - A CMake variable name containing a list that the C++ header path should be appended to | |
# OUTPUT_CPP_HH_VAR - A CMake variable name containing a list generated headers should be appended to | |
# OUTPUT_DETAIL_CPP_HH_VAR - A CMake variable name containing a list that the C++ detail headers should be appended to | |
# OUTPUT_CPP_CC_VAR - A Cmake variable name containing a list that the C++ source files should be appended to | |
# OUTPUT_PYTHON_VAR - A Cmake variable name containing a list that the python file should be appended to | |
# GENERATE_PYTHON - generates python code for the message if specified | |
# One value arguments: | |
# MSGS_GEN_SCRIPT - Path to the message generation python script | |
# PROTO_PACKAGE - Protobuf package the file belongs to (e.g. "gz.msgs") | |
# PROTOC_EXEC - Path to protoc | |
# GZ_PROTOC_PLUGIN - Path to the gazebo-specific protobuf compiler executable | |
# INPUT_PROTO - Path to the input .proto file | |
# OUTPUT_CPP_DIR - Path where C++ files are saved | |
# OUTPUT_PYTHON_DIR - Path where Python files are saved | |
# OUTPUT_INCLUDES - A CMake variable name containing a list that the C++ header path should be appended to | |
# OUTPUT_CPP_HH_VAR - A CMake variable name containing a list generated headers should be appended to | |
# OUTPUT_DETAIL_CPP_HH_VAR - A CMake variable name containing a list that the C++ detail headers should be appended to | |
# OUTPUT_CPP_CC_VAR - A Cmake variable name containing a list that the C++ source files should be appended to | |
# OUTPUT_PYTHON_VAR - A Cmake variable name containing a list that the python file should be appended to |
@@ -0,0 +1,32 @@ | |||
# Copyright (C) 2022 Open Source Robotics Foundation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# Copyright (C) 2022 Open Source Robotics Foundation | |
# Copyright (C) 2023 Open Source Robotics Foundation |
Closing since #362 is sufficient. |
🎉 New feature
Summary
Uses the new message generation framework to generate protobuf python files. This will be used by gazebosim/gz-transport#411. Since we won't be concerned with ABI issues for python files, I think it would be okay to provide binary distributions for the generated files.
Test it
Checklist
codecheck
passed (See contributing)Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining
Signed-off-by
messages.