forcediphttpsadapter
forcediphttpsadapter copied to clipboard
ForcedIPHTTPSAdapter is not pickleable
from forcediphttpsadapter.adapters import ForcedIPHTTPSAdapter
import pickle
adapter = ForcedIPHTTPSAdapter(dest_ip='127.0.0.1')
pickle.loads(pickle.dumps(adapter))
throws: AttributeError: 'ForcedIPHTTPSAdapter' object has no attribute 'dest_ip'
The problem is that "dest_ip" field is not returned in __getstate__ method.