diff --git a/xonsh/shell.py b/xonsh/shell.py index aa78fb15c..095160c39 100644 --- a/xonsh/shell.py +++ b/xonsh/shell.py @@ -112,7 +112,7 @@ class Shell(object): names = builtins.__xonsh_config__.get('xontribs', ()) for name in names: update_context(name, ctx=self.ctx) - if hasattr(update_context, 'bad_imports'): + if getattr(update_context, 'bad_imports', None): prompt_xontrib_install(update_context.bad_imports) del update_context.bad_imports # load run control files