我已经在这里呆了45分钟了。我急需帮助。在
当我运行这个:
import urllib, urllib2
proxy = urllib2.ProxyHandler({
'http': '127.0.0.1',
'https': '127.0.0.1'
})
opener = urllib2.build_opener(proxy)
urllib2.install_opener(opener)
# this way both http and https requests go through the proxy
urllib2.urlopen('http://www.google.com')
urllib2.urlopen('https://www.google.com')
我明白了:
^{pr2}$更新:
修复了随机.py发布并获得:
^{3}$
当前目录中有一个名为
random.py
的文件。将其重命名为random_.py
。在注意,使用
C:\Python27
中的文件进行开发可能不是一个好的实践。在相关问题 更多 >
编程相关推荐