def StringIO(*args, **kw):
global StringIO<EOL>try:<EOL><INDENT>from io import StringIO<EOL><DEDENT>except ImportError:<EOL><INDENT>from io import StringIO<EOL><DEDENT>return StringIO(*args,**kw)<EOL>
Thunk to load the real StringIO on demand