module ‘urllib‘ has no attribute ‘urlretrieve‘

在使用urllib的时候,报的错。
正确的方式:

import urllib.request


urllib.request.urlretrieve('XXXX.jpg', 'aa.png')

猜你喜欢

转载自blog.csdn.net/hhhhhhhhhhwwwwwwwwww/article/details/125787363