<s> '''<STR_LIT>''' <EOL> import tempfile <EOL> import shutil <EOL> try : <EOL> import pathlib <EOL> except : <EOL> from python_toolbox . third_party import pathlib <EOL> from python_toolbox import context_management <EOL> @ context_management . ContextManagerType <EOL> def create_temp_folder ( suffix = '<STR_LIT>' , prefix = tempfile . template ) : <EOL> '''<STR_LIT>''' <EOL> temp_folder = pathlib . Path ( tempfile . mkdtemp ( suffix = suffix , prefix = prefix ) ) <EOL> yield temp_folder <EOL> shutil . rmtree ( str ( temp_folder ) ) </s>
