'make a date-marked backup of the specified file, return True or False on success or failure'

def backup_local(self, fn):

    backupdest = ''
    if os.path.exists(fn):
        ext = time.strftime('%Y-%m-%d@%H:%M:%S~', time.localtime(time.time()))
        backupdest = ('%s.%s.%s' % (fn, os.getpid(), ext))
        try:
            self.preserved_copy(fn, backupdest)
        except (shutil.Error, IOError):
            e = get_exception()
            self.fail_json(msg=('Could    not    make    backup    of    %s    to    %s:    %s' % (fn, backupdest, e)))
    return backupdest
