def __exit__(self, exc_type, exc_value, traceback):
if isinstance(exc_value, AlreadyRegisteredError):<EOL><INDENT>self.cfg.gc = self.backup.copy()<EOL>return True<EOL><DEDENT>
If the execution fails, keep previous configutation.