Skip to content

Commit

Permalink
Check oauthlib installation when importing asynchronous subpackage
Browse files Browse the repository at this point in the history
  • Loading branch information
Harmon758 committed May 16, 2021
1 parent a02e54b commit b0b2322
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tweepy/asynchronous/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,11 @@

try:
import aiohttp
import oauthlib
except ModuleNotFoundError:
from tweepy.errors import TweepyException
raise TweepyException("tweepy.asynchronous requires aiohttp to be installed")
raise TweepyException(
"tweepy.asynchronous requires aiohttp and oauthlib to be installed"
)

from tweepy.asynchronous.streaming import AsyncStream

0 comments on commit b0b2322

Please sign in to comment.