From 44bc9406756c3e3d95e477ef3bfad2a5bc177a33 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juhani=20Krekel=C3=A4?= Date: Sat, 1 Sep 2018 21:43:35 +0300 Subject: [PATCH] Chain throws --- src/main-export-known-hosts.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main-export-known-hosts.py b/src/main-export-known-hosts.py index 63288b9..6cda64c 100644 --- a/src/main-export-known-hosts.py +++ b/src/main-export-known-hosts.py @@ -48,8 +48,8 @@ def main(): try: homedir = os.environ['HOME'] - except KeyError: - raise KeyError('$HOME is not set') + except KeyError as err: + raise KeyError('$HOME is not set') from err # The input file # Default to ~/.ssh/known_hosts