作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
hi i am new to python and i got this error but i have installed twitter but it's giving this error
import twitter
api=twitter.Api()
Traceback (most recent call last):
File "<pyshell#1>", line 1, in <module>
api=twitter.Api()
AttributeError:'module' object has no attribute 'Api'
我不知道这个错误,因为我几乎有与 twitter 相关的每个包
Traceback (most recent call last):
File "<pyshell#2>", line 1, in <module>
api = twitter.Api()
AttributeError: 'module' object has no attribute 'Api'
当我发出这个命令时python setup.py install_data它给出这样的错误运行install_data
Traceback (most recent call last) :
file "setup.py" ,line 47 , <module>
""" ,
File "C:\python26\lib\distutils\core.py" ,line 152 , in setup
dist.run_commands()
File "C:\python26\lib\distutils\dist.py" ,line 975 , in run_commands
self.run_command(cmd)
File "C:\python26\lib\distutils\dist.py" ,line 995 , in run_commands
command_obj.run
File "C:\python26\lib\distutils\command\install_data.py" , line 44 in run
For f in self.data_files
最佳答案
您可以使用重新安装吗,
sudo pip install twitter
或
sudo easy_install twitter
旧版本不需要 OAuth,但新版本需要。最新版本的文档需要这些来启动API
>>> api = twitter.Api(consumer_key='consumer_key',
consumer_secret='consumer_secret', access_token_key='access_token', access_token_secret='access_token_secret')
关于python - twitter Api 使用 python 给出错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11835882/
我有一个经典的 ASP 页面 (VBscript),它在服务器端生成 XML,然后 Response.Writes。该页面根本没有客户端。 但是我需要将其转换为 JSON。由于我找不到有效的 ASP
我想从客户端应用程序的 HDFS 中读取特定的 SequenceFile。我可以使用 SequenceFile.Reader 来做到这一点,它工作正常。但是是否也可以通过分析抛出的 IOExcepti
我是一名优秀的程序员,十分优秀!