def add_failure_cleanup(self, function, *args, **kwargs):
with self._failure_cleanups_lock:<EOL><INDENT>self._failure_cleanups.append(<EOL>FunctionContainer(function, *args, **kwargs))<EOL><DEDENT>
Adds a callback to call upon failure