def suppressWarnings(f, *suppressedWarnings):
 def warningSuppressingWrapper(*a, **kw):
  return runWithWarningsSuppressed(suppressedWarnings, f, *a, **kw)
 return tputil.mergeFunctionMetadata(f, warningSuppressingWrapper)

def suppressWarnings ( f , * suppressedWarnings ) : def warningSuppressingWrapper ( * a , ** kw ) : return runWithWarningsSuppressed ( suppressedWarnings , f , * a , ** kw ) return tputil . mergeFunctionMetadata ( f , warningSuppressingWrapper )
wrap c{f} in a callable which suppresses the indicated warnings before invoking c{f} and unsuppresses them afterwards .