无法在vim scrip中使用urllib2模块

2024-09-28 03:22:51 发布

您现在位置:Python中文网/ 问答频道 /正文

我无法在vim脚本中使用urllib2模块:

if !has('python')
    finish
endif

function! PrintForecastInfo()

python << EOF

import urllib2

rp5_url = 'http://rp5.ru/'

response = urllib2.urlopen(rp5_url).read()

EOF
endfunc

此代码导致以下错误:

ImportError: DLL load failed: The specified procedure could not be found

为什么?我做错什么了?我该怎么修?你知道吗

我用的是Windows8


Tags: 模块import脚本httpurliffunctionvim

热门问题