@contextlib.contextmanager
def ignored(*exceptions):
 try:
  (yield)
 except exceptions:
  pass

@ contextlib . contextmanager def ignored ( * exceptions ) : try : ( yield ) except exceptions : pass
context manager that ignores all of the specified exceptions .