Unable to find Protobuf include directory during install mysql-connector over pip

wei.lu picture wei.lu · Mar 26, 2017 · Viewed 24.6k times · Source

I pulled mysql-connector-python code and when I run python ./setup.py build I get the following error:

Unable to find Protobuf include directory.

pip install Protobuf was useless

How can I solve this problem?

Answer

yutaka2487 picture yutaka2487 · Mar 28, 2017

I found that this error occurs since version 2.2.3. You can avoid this issue using version 2.1.6.

pip install mysql-connector==2.1.6

try above.