diff options
author | Oleg Pudeyev <code@olegp.name> | 2021-07-20 16:05:38 -0400 |
---|---|---|
committer | Oleg Pudeyev <code@olegp.name> | 2021-07-20 16:05:38 -0400 |
commit | 72c667fc5018f858ea0e14f7894759821144cdff (patch) | |
tree | f7ec13d8e5619747050a0509e2f328db4dd8ec27 | |
parent | 148e5822d415888126c54f1d893c8115cc46ec11 (diff) | |
download | pycurl-72c667fc5018f858ea0e14f7894759821144cdff.tar.gz |
document pycurl vs requests, closes #309
-rw-r--r-- | doc/index.rst | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/doc/index.rst b/doc/index.rst index d407692..60845b0 100644 --- a/doc/index.rst +++ b/doc/index.rst @@ -23,6 +23,33 @@ libcurl, including: .. _Tornado: http://www.tornadoweb.org/ +PycURL vs Requests +------------------ + +`Requests <https://docs.python-requests.org/>`_ is another popular Python +library that is frequently compared to PycURL. + +Advantages of PycURL: + +- PycURL can be `several times faster than Requests + <https://github.com/svanoort/python-client-benchmarks>`_. + The performance difference is larger when there are multiple requests + performed and connections are reused. +- PycURL makes it possible to take advantage of I/O multiplexing via the + `libcurl multi interface <https://curl.haxx.se/libcurl/c/libcurl-multi.html>`_. +- PycURL supports many protocols, not just HTTP. +- PycURL generally provides more features, for example ability to use several + TLS backends, more authentication options, etc. + +Advantages of Requests: + +- Requests is written in pure Python and does not require C extensions. + As a result, Requests is trivial to install while PycURL's installation + can be complex (though operating system-specific packages, if available, + negate this drawback). +- Requests' API is generally easier to learn and use than PycURL's. + + About libcurl ------------- |