pypath.share.curl.preserve_on§
- class pypath.share.curl.preserve_on[source]§
Bases:
_global_context_on
This is a context handler which results pypath.curl.Curl() to make a reference to itself in the module level variable LASTCURL. This is useful if you have some issue with Curl, and you want to access the instance for debugging.
Behind the scenes it sets the value of the pypath.curl.PRESERVE module level variable to True (by default it is False).
Example:
import pypath from pypath import curl, data_formats pa = pypath.PyPath() with curl.cache_preserve_on(): pa.load_resources({'signor': data_formats.pathway['signor']})
Methods
__init__
()- param str name:
Name of the module level variable.