From 2ec0f5c6afba569f2b018ff4d9a72303a69961b0 Mon Sep 17 00:00:00 2001 From: Moul <moul@moul.re> Date: Sun, 2 May 2021 16:20:25 +0200 Subject: [PATCH] [mod] #396: wot: Handle 404 error not found exception Remove useless ValueError exception --- silkaj/wot.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/silkaj/wot.py b/silkaj/wot.py index 0a546501..fc29d998 100644 --- a/silkaj/wot.py +++ b/silkaj/wot.py @@ -16,6 +16,7 @@ along with Silkaj. If not, see <https://www.gnu.org/licenses/>. """ import click +import urllib from time import time from tabulate import tabulate from collections import OrderedDict @@ -251,8 +252,8 @@ def wot_lookup(identifier): return results["results"] except DuniterError as e: message_exit(e.message) - except ValueError as e: - pass + except urllib.error.HTTPError as e: + message_exit(e) def identities_from_pubkeys(pubkeys, uids): -- GitLab