From 12e2cd617842c7b017c20685879bb2f5406a06cb Mon Sep 17 00:00:00 2001 From: Kirill Pinchuk Date: Mon, 21 Aug 2017 17:28:29 +0300 Subject: [PATCH] Catch BaseException in safe_getattr --- _pytest/compat.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_pytest/compat.py b/_pytest/compat.py index 45f9f86d45c..361a68ea48a 100644 --- a/_pytest/compat.py +++ b/_pytest/compat.py @@ -228,7 +228,7 @@ def safe_getattr(object, name, default): """ try: return getattr(object, name, default) - except Exception: + except BaseException: return default