#6446: fix import_spam() function to use correct error and reference handling.
#6446: fix import_spam() function to use correct error and reference handling.

sk-/python2.7-type-annotator,sk-/python2.7-type-annotator,sk-/python2.7-type-annotator