Missing something obvious with python-requests

R

Ray Cote

Hello List:

I seem to be missing something obvious in terms of using proxies with the requests module.
I'm using requests 1.4 and Python 2.7. Have tried this on Centos 6 and Windows XP.

Here's the sample code, right out of the manual:

import requests

proxies = {
'https': '192.168.24.25:8443',
'http': '192.168.24.25:8443', }

a = requests.get('http://google.com/', proxies=proxies)


When I look at the proxy log, I see a GET being performed -- when it should be a CONNECT.
Does not matter if I try to get http or https google.com.
Clearly I'm missing something fundamental here.
But after two days of fiddling with the code and tracing through requests I'm still unclear as to why requests is not using the proxy information.

Any help (or slap on the side of the head) appreciated.
Thanks
--Ray
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,020
Latest member
GenesisGai

Latest Threads

Top