aparo / pyes

Python connector for ElasticSearch - the pythonic way to use ElasticSearch
BSD 3-Clause "New" or "Revised" License
607 stars 270 forks source link

pypy failure fix on fastbinary import with "AttributeError" #513

Closed frail closed 7 years ago

frail commented 7 years ago

we hit this bug when we are using this library with pypy:

Traceback (most recent call last): File "/venv/pypy/site-packages/commons/app.py", line 251, in run main() File "/repo/start.py", line 14, in start_daemon import configuration File "/repo/configuration.py", line 14, in from pyes import ES File "/venv/pypy/site-packages/pyes/init.py", line 26, in from .es import ES, file_to_attachment File "/venv/pypy/site-packages/pyes/es.py", line 41, in from .connection import connect as thrift_connect File "/venv/pypy/site-packages/pyes/connection.py", line 12, in from .pyesthrift import Rest File "/venv/pypy/site-packages/pyes/pyesthrift/Rest.py", line 9, in from .ttypes import * File "/venv/pypy/site-packages/pyes/pyesthrift/ttypes.py", line 12, in from thrift.protocol import fastbinary AttributeError: 'module' object has no attribute 'cStringIO_CAPI'

we assumed that the bug is due to this issue in pypy:

https://bitbucket.org/pypy/pypy/issues/875/thrift-installation-error-cstringioh