Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the difference between pycurl and curl in python

Newbie question: Python 2.6, Ubuntu 10.04, I can import both pycurl and curl, the former having different names for functions (set_option vs. setopt).

What's the difference between the two modules?

like image 985
alexef Avatar asked Aug 31 '10 14:08

alexef


People also ask

Is PycURL the same as curl?

curl is a module which uses pycurl . It provides the curl. Curl class which provides a high-level interface to the pycurl functions.

What is PycURL in Python?

PycURL is a Python interface to libcurl, the multiprotocol file transfer library. Similarly to the urllib Python module, PycURL can be used to fetch objects identified by a URL from a Python program.


1 Answers

curl is a module which uses pycurl. It provides the curl.Curl class which provides a high-level interface to the pycurl functions.

I haven't found much documentation on how to use it, but reading /usr/share/pyshared/curl/__init__.py may make it pretty self-obvious.

There are also some examples in /usr/share/doc/python-pycurl/examples which use curl.Curl.

like image 122
unutbu Avatar answered Nov 09 '22 18:11

unutbu