nest context managers for py26 compatibility
unicode to py2help.basestring