Home  >  Q&A  >  body text

python - 用rllib.request.urlretrieve下载东西,为什么会出现这个错误

我不知道为什么出错,新手小白向各位大神求就~~

代码:
import urllib.request
urls = ['http://paper.people.com.cn/rm...{}.htm'.format(str(0)+str(i) if len(str(i))==1 else str(i)) for i in range(1,18,1)]
print(urls)

folder_path = '/Users/sufan/Desktop/','w'

for url in urls:

urllib.request.urlretrieve(url)
高洛峰高洛峰2740 days ago797

reply all(1)I'll reply

  • 大家讲道理

    大家讲道理2017-04-18 10:27:08

    404 Address not found. You can try putting the request in the browser

    reply
    0
  • Cancelreply