From 9a9e2f098942d733537a0c4fc21af0b948d12db3 Mon Sep 17 00:00:00 2001 From: Harmon Date: Fri, 22 Jan 2021 18:18:25 -0600 Subject: [PATCH] Close requests Session at the end of Stream._run --- tweepy/streaming.py | 1 + 1 file changed, 1 insertion(+) diff --git a/tweepy/streaming.py b/tweepy/streaming.py index 5323cba..4342673 100644 --- a/tweepy/streaming.py +++ b/tweepy/streaming.py @@ -210,6 +210,7 @@ class Stream: self.listener.on_exception(exc) raise finally: + self.session.close() self.running = False def _read_loop(self, resp): -- 2.25.1