Fix for issue #1041, dict has no attrib entries error