pycurl

SSL backend error when using OpenSSL

跟風遠走 提交于 2019-11-26 17:58:36
问题 I was trying to install pycurl in a virtualenv using pip and I got this error ImportError: pycurl: libcurl link-time ssl backend (openssl) is different from compile-time ssl backend (none/other) I read some documentation saying that "To fix this, you need to tell setup.py what SSL backend is used" (source) although I am not sure how to do this since I installed pycurl using pip. How can I specify the SSL backend when installing pycurl with pip? Thanks 回答1: After reading their INSTALLATION

Python Requests vs PyCurl Performance

霸气de小男生 提交于 2019-11-26 17:31:57
问题 How does the Requests library compare with the PyCurl performance wise? My understanding is that Requests is a python wrapper for urllib whereas PyCurl is a python wrapper for libcurl which is native, so PyCurl should get better performance, but not sure by how much. I can't find any comparing benchmarks. 回答1: I wrote you a full benchmark , using a trivial Flask application backed by gUnicorn/meinheld + nginx (for performance and HTTPS), and seeing how long it takes to complete 10,000

Why can't Python find shared objects that are in directories in sys.path?

…衆ロ難τιáo~ 提交于 2019-11-26 03:29:24
问题 I\'m trying to import pycurl : $ python -c \"import pycurl\" Traceback (most recent call last): File \"<string>\", line 1, in <module> ImportError: libcurl.so.4: cannot open shared object file: No such file or directory Now, libcurl.so.4 is in /usr/local/lib . As you can see, this is in sys.path : $ python -c \"import sys; print(sys.path)\" [\'\', \'/usr/local/lib/python2.5/site-packages/setuptools-0.6c9-py2.5.egg\', \'/usr/local/lib/python25.zip\', \'/usr/local/lib/python2.5\', \'/usr/local