From 7e86cbabe881e7db4087625a7f6b1ec1543972ed Mon Sep 17 00:00:00 2001 From: mohammed chamma Date: Wed, 30 Dec 2020 18:39:56 -0500 Subject: [PATCH] use id as hash since its an integer Co-authored-by: Harmon --- tweepy/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tweepy/models.py b/tweepy/models.py index aceb398..ac0de53 100644 --- a/tweepy/models.py +++ b/tweepy/models.py @@ -227,7 +227,7 @@ class User(Model): def __hash__(self): if hasattr(self, 'id'): - return hash(self.id) + return self.id else: raise TypeError('unhashable type: {} (no id attribute)'.format(type(self))) -- 2.25.1