From c7b51bfe19ff473481e3b292e8b9c85d256725ff Mon Sep 17 00:00:00 2001 From: ophirharpazg Date: Tue, 1 Sep 2020 15:42:46 +0300 Subject: [PATCH] print stack trace in exception --- monkey/infection_monkey/exploit/HostExploiter.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/monkey/infection_monkey/exploit/HostExploiter.py b/monkey/infection_monkey/exploit/HostExploiter.py index 86c966c92..274d07329 100644 --- a/monkey/infection_monkey/exploit/HostExploiter.py +++ b/monkey/infection_monkey/exploit/HostExploiter.py @@ -73,8 +73,8 @@ class HostExploiter(Plugin): result = None try: result = self._exploit_host() - except Exception as e: - logger.warning(f'Exception in exploit_host: {e}') + except Exception as _: + logger.error(f'Exception in exploit_host', exc_info=True) finally: self.post_exploit() return result