'Create a temporary file on the same filesystem as
self.association_dir.
The temporary directory should not be cleaned if there are any
processes using the store. If there is no active process using
the store, it is safe to remove all of the files in the
temporary directory.
() -> (file, str)'

def _mktemp(self):

    (fd, name) = mkstemp(dir=self.temp_dir)
    try:
        file_obj = os.fdopen(fd, 'wb')
        return (file_obj, name)
    except:
        _removeIfPresent(name)
        raise
