Fix import_attr bug pointed out by David Schaurecker

This commit is contained in:
Yin Li 2020-08-21 14:02:07 -05:00
parent 4799f8177c
commit b215c0fa7b

View File

@ -42,7 +42,7 @@ def import_attr(name, *pkgs, callback_at=None):
try:
return getattr(
importlib.import_module(pkg.__name__ + '.' + mod), attr)
except (ModuleNotFoundError, AttributeError):
except (ModuleNotFoundError, AttributeError) as e:
errors.append(e)
if callback_at is None: