mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eric Chung <>
Subject Re: Review Request 66649: Added for generating python protobuf bindings.
Date Tue, 17 Apr 2018 20:22:00 GMT

This is an automatically generated e-mail. To reply, visit:

(Updated April 17, 2018, 8:22 p.m.)

Review request for mesos, Armand Grillet, Jason Lai, Kevin Klues, and Zhitao Li.

Repository: mesos

Description (updated)

The current state of support for python in protoc has two serious
1. The `` files necessary to mark a directory as a python
package aren't generated.
2. The import paths in each of the generated .py files do not reflect
the `--python_path` option passed to `protoc`.

This results in incomplete code generated, preventing it from being used
out of the box. To address this issue, we're adding a `` script
to do end-to-end code generation for python protobuf bindings: the
script generates the bindings based on what's in the `include` dir, then
postprocesses the generated code to add proper import paths and the
`` files.

Diffs (updated)

  src/python/lib/ PRE-CREATION 
  src/python/lib/ 0742f3d846c99c1c4907d9628fb49845564563b2 




1. under `src/python/lib`, run ``
2. initialize and activate virtualenv: `virtualenv env && . env/bin/activate`
3. install reqs: `pip install -r`
4. try to import modules from generated python code: `python -c 'from mesos.pb2.mesos.v1.master
import master_pb2'`


Eric Chung

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message