Closed alanwangmodify closed 8 years ago
` up = upyun.UpYun('*_', secret='_**', endpoint=upyun.ED_AUTO)
with open('contentImg.jpg', 'rb') as f: res = up.put('/style/xinu.jpg', f, checksum=True, need_resume=True) ` 一直 报错 : AttributeError: 'UpYun' object has no attribute 'up_rest'
只有 rest api 支持断点续传, 需要 username 和 password up = upyun.UpYun('bucket', username='username', password='password')
up = upyun.UpYun('bucket', username='username', password='password')
好的,谢谢,问题解决了,是想要表单上传,弄错代码了
` up = upyun.UpYun('*_', secret='_**', endpoint=upyun.ED_AUTO)
with open('contentImg.jpg', 'rb') as f:
res = up.put('/style/xinu.jpg', f, checksum=True, need_resume=True) ` 一直 报错 : AttributeError: 'UpYun' object has no attribute 'up_rest'