Bugfix : the handling of AttributeError does not work for some_module.mispelled_attribute

I don't know what the real fix should be but I've written a test to ensure we don't epicly
refail in the future.