switched StringIO to io