From: Harmon Date: Sat, 23 Oct 2021 16:49:05 +0000 (-0500) Subject: Add FAQ section on StreamListener for v4 X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=951fb19ddbf0a61d3624b879a239bef4e92c5460;p=tweepy.git Add FAQ section on StreamListener for v4 --- diff --git a/docs/faq.rst b/docs/faq.rst index dd904c3..9f5378f 100644 --- a/docs/faq.rst +++ b/docs/faq.rst @@ -73,6 +73,18 @@ These parameters can be passed as keyword arguments instead. Refer to the documentation for the :class:`API` method being used. +Where did ``StreamListener`` go? +-------------------------------- + +If you're attempting to import ``StreamListener`` with Tweepy v4, you'll get an +:class:`AttributeError` about ``tweepy`` not having a ``StreamListener`` +attribute. + +This is because Tweepy v4.0.0 merged ``StreamListener`` into :class:`Stream`. + +To use Tweepy v4, you'll need to update your code to subclass :class:`Stream` +instead. + Twitter API v2 ==============