colour.utilities.ignore_python_warnings#

colour.utilities.ignore_python_warnings(function: Callable) Callable[source]#

Decorate a function to ignore Python warnings.

Parameters:

function (Callable) – Function to decorate.

Return type:

Callable

Examples

>>> @ignore_python_warnings
... def f():
...     warnings.warn("This is an ignored warning!")
>>> f()