def save_processed_files(path, processed_files):
 try:
  path_dir = os.path.dirname(path)
  if (not os.path.exists(path_dir)):
   os.makedirs(path_dir)
 except OSError as exc:
  raise IOError(exc)
 with open(path, 'w') as output_file:
  for (path, timestamp) in list(processed_files.items()):
   if (not os.path.isabs(path)):
    raise TypeError(('Only absolute paths are acceptable: %s' % path))
   output_file.write(('%s %i\n' % (path, timestamp)))

def save_processed_files ( path , processed_files ) : try : path_dir = os . path . dirname ( path ) if ( not os . path . exists ( path_dir ) ) : os . makedirs ( path_dir ) except OSError as exc : raise IOError ( exc ) with open ( path , 'w' ) as output_file : for ( path , timestamp ) in list ( processed_files . items ( ) ) : if ( not os . path . isabs ( path ) ) : raise TypeError ( ( 'Only absolute paths are acceptable: %s' % path ) ) output_file . write ( ( '%s %i\n' % ( path , timestamp ) ) )
persists a dictionary of path => last modified timestamp mappings so that they can be loaded later and applied to another :class:~stem .