Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试使用 tweepy 进行简单请求,以获取有关特定用户屏幕名称的信息。我这样做了:
import tweepy api = tweepy.API api.get_user('name')
我得到错误:
unbound method _call() must be called with API instance as first argument (got str instance instead)
您需要创建 API 的一个实例:
api = tweepy.API() api.get_user('name')
演示总是更有启发性:
>>> import tweepy >>> api = tweepy.API() >>> api.get_user('zopatista') <tweepy.models.User object at 0x10ffcd910>
嗨,如果这是一个简单的问题,我深表歉意,因为我对编程还很陌生。这是一个 Ruby on Rails 应用程序。我有一个 API 正在侦听来自我们的供应商之一的推送通知。当供应商点击 API 时,我收到此错误:
==> log/beta.log <== rack-cache (1.2) lib