upyun / python-sdk

UPYUN Python SDK
117 stars 29 forks source link

AttributeError: 'UpYun' object has no attribute 'up_rest' #45

Closed alanwangmodify closed 8 years ago

alanwangmodify commented 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'

huangnauh commented 8 years ago

只有 rest api 支持断点续传, 需要 username 和 password up = upyun.UpYun('bucket', username='username', password='password')

alanwangmodify commented 8 years ago

好的,谢谢,问题解决了,是想要表单上传,弄错代码了