human
I wrote the below code

    def capture(function):
        @functools.wraps(function)
        def captured_function(*args, **kwargs):
            try:
                return function(*args, **kwargs)
            except Exception as exc:
                async_result.set_exception(exc)
        return captured_function
    return capture

What's a good function header?

Here's a good function header?
assistant
#Here's a good function header.

def capture_exceptions(async_result):