(*args, **kwargs)
| 8 | when the function is used.""" |
| 9 | @functools.wraps(func) |
| 10 | def new_func(*args, **kwargs): |
| 11 | warnings.simplefilter('always', DeprecationWarning) # turn off filter |
| 12 | warnings.warn("Call to deprecated function {}.".format(func.__name__), |
| 13 | category=DeprecationWarning, |
| 14 | stacklevel=2) |
| 15 | warnings.simplefilter('default', DeprecationWarning) # reset filter |
| 16 | return func(*args, **kwargs) |
| 17 | return new_func |
nothing calls this directly
no outgoing calls
no test coverage detected