I'd like to get the Cookies that have been carried with the response (
Set-Cookie: name=value; ...
set_cookies = 
TypeError: c.getinfo() takes exactly 1 argument (2 given)
set_cookies = c.getinfo(c.COOKIELIST)
ValueError: invalid argument to getinfo
With very few exceptions, PycURL constants are derived from libcurl constants by removing the CURLINFO_ prefix.
There's no method to get response cookies after calling
perform(). Headers sent by the server can be captured using a callback function passed to the PyCurl instance while configuring with
Callback for writing received headers. See CURLOPT_HEADERFUNCTION
Example code excerpt:
set_cookies =  # closure to capture Set-Cookie def _write_header(header): match = re.match("^Set-Cookie: (.*)$", header) if match: set_cookies.append(match.group(1)) # use closure to collect cookies sent from the server c.setopt(pycurl.HEADERFUNCTION, _write_header)