Pure python code for cyber-record reader/writer, build with bazel
Based on cyber-record 0.1.12 and extracted from whl, you can use pip install cyber-record if it is still works well with your protobuf version.
- The official cyber record reader from Apollo is based on C++ and needs apollo build environment to run, which is not convenient for users who are not familiar with Apollo.
- The third-party cyber-record which is pure python code is not updated for a long time(2022, 0.1.12), and it limits the protobuf version 3.19.4, which blocks my development.
- So I need a light-weighted cyber-record reader/writer which is pure python code and can be used in any environment.
- I did not make it as a whl because I want make it flexible for different protobuf version, some APIs needs to be modified accord to your protobuf version.
- With bazel:
- Install bazel, and also prepare yoru
WORKSPACEfile, andrequlirements.txt; - Clone this repo, copy the
cyber_recordfolder to your project; - Build with bazel;
- Without bazel:
- Clone this repo, copy the
cyber_recordfolder to your project; - Install protobuf:
pip install protobuf; - Install use protoc update pb2.py, and replace the one in repo:
protoc --python_out=. *.proto;
- Updated the method to get
message_typeto keep compatible with protobuf new versions; - Fix the README.md version error in update log part;
- Based on cyber-record 0.1.12 and extracted from whl;
- Added
BUILDfiles for bazel; - Added
protofiles from project Apollo to replace thepb2.pyfiles (verified with libprotoc 28.3, generatedpb2.pykeep unchanged); - Removed useless not referenced
.pyfiles; - Removed useless
.pycfiles; - Formated code with black-formatter;