gns24 / pydatomic

Python library for accessing the datomic DBMS
88 stars 16 forks source link

Allow this to work under gevent by using grequests #6

Open richtera opened 10 years ago

richtera commented 10 years ago

Check whether gevent is loader and if it is, then use grequests instead of requests. Otherwise this module hangs a system with gevent loaded.

richtera commented 10 years ago

Sorry this patch is not quite right.

richtera commented 10 years ago

This now works although I figured out the hang was due to the fact that uwsgi's main thread (the one loading the wsgi file) is suspended and cannot be used to make requests, httplib2 or urllib3 calls. At least this is what cleared out my hangs.