From 6739045cce6f76fc8d8c53479460fc132fabe576 Mon Sep 17 00:00:00 2001 From: Manuel Cortez Date: Thu, 28 Oct 2021 13:18:02 -0500 Subject: [PATCH] Fixed manual addition of users to the autocomplete users database --- src/extra/autocompletionUsers/manage.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/extra/autocompletionUsers/manage.py b/src/extra/autocompletionUsers/manage.py index 1d724e4f..a1acd603 100644 --- a/src/extra/autocompletionUsers/manage.py +++ b/src/extra/autocompletionUsers/manage.py @@ -1,5 +1,6 @@ # -*- coding: utf-8 -*- import widgetUtils +from tweepy.errors import TweepyException from . import storage, wx_manage from wxUI import commonMessageDialogs @@ -27,8 +28,9 @@ class autocompletionManage(object): if usr == False: return try: - data = self.session.twitter.twitter.get_user(screen_name=usr) - except: + data = self.session.twitter.get_user(screen_name=usr) + except TweepyException as e: + log.exception("Exception raised when attempting to add an user to the autocomplete database manually.") self.dialog.show_invalid_user_error() return self.database.set_user(data.screen_name, data.name, 0)