Dropbox AttributeError:'module'对象没有属性'Dropbox'

时间:2017-11-03 14:51:43

标签: python dropbox

我是python的新手。我想尝试最简单的Dropbox示例。

import dropbox
dbx = dropbox.Dropbox('access_token')
dbx.users_get_current_account()

但它给了我以下错误:

Traceback (most recent call last):
  File "/Users/Peezy/Desktop/test.py", line 2, in <module>
    dbx = dropbox.Dropbox('access_token')
AttributeError: 'module' object has no attribute 'Dropbox'
[Finished in 0.2s with exit code 1]
[shell_cmd: python -u "/Users/Peezy/Desktop/test.py"]
[dir: /Users/Peezy/Desktop]
[path: /Library/Frameworks/Python.framework/Versions/3.6/bin:/opt/local/bin:/opt/local/sbin:/Library/Frameworks/Python.framework/Versions/2.7/bin:/Library/Frameworks/Python.framework/Versions/3.4/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin:/usr/local/aria2/bin:/opt/X11/bin]

在我看来,python没有找到我的Dropbox库。我已经使用“sudo pip install dropbox”正确安装了Dropbox(至少我是这么认为的)。我该如何解决这个问题?

0 个答案:

没有答案