From b9794806d7bbe428f7698fe76393600a36ec3dd7 Mon Sep 17 00:00:00 2001 From: Manuel Cortez Date: Tue, 16 Aug 2022 17:11:50 -0500 Subject: [PATCH] Display error when attempting to open a TL for an unauthorized user. Closes #485 --- doc/changelog.md | 1 + src/controller/mainController.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/changelog.md b/doc/changelog.md index e55b8edb..6d9572a3 100644 --- a/doc/changelog.md +++ b/doc/changelog.md @@ -9,6 +9,7 @@ TWBlue Changelog * Fixed error when attempting to mention an user by using the "mention" button in any people buffer. Now tweets should be posted normally. * Fixed error when loading other user lists. ([#465](https://github.com/MCV-Software/TWBlue/issues/465)) * Fixed an issue that was making TWBlue to display incorrectly some retweets of quoted tweets. +* If TWBlue is unable to open a timeline for someone who has blocked you, this will be reported in a dialog. ([#485,](https://github.com/mcv-software/twblue/issues/485)) * Added "find a string in the currently focused buffer" action into Windows 10 and windows 11 keymap. ([#476](https://github.com/MCV-Software/TWBlue/pull/476)) ## changes in version 22.2.23 diff --git a/src/controller/mainController.py b/src/controller/mainController.py index c796eb34..c6fd6f52 100644 --- a/src/controller/mainController.py +++ b/src/controller/mainController.py @@ -869,7 +869,7 @@ class Controller(object): tl = buffers.twitter.BaseBuffer(self.view.nb, "user_timeline", "%s-timeline" % (usr.id_str,), buff.session, buff.session.db["user_name"], bufferType=None, sound="tweet_timeline.ogg", user_id=usr.id_str, include_ext_alt_text=True, tweet_mode="extended") try: tl.start_stream(play_sound=False) - except ValueError: + except TweepyException: commonMessageDialogs.unauthorized() return pos=self.view.search("timelines", buff.session.db["user_name"])