def asyncflux_coroutine(f):
    coro = gen.coroutine(f)

    @functools.wraps(f)
    def wrapper(*args, **kwargs):
        callback = kwargs.pop('callback', None)
        if callback and not callable(callback):
            raise TypeError("callback must be a callable")
        future = coro(*args, **kwargs)
        if callback:
            def _callback(future):
                try:
                    result = future.result()
                    callback(result, None)
                except Exception as e:
                    callback(None, e)
            future.add_done_callback(_callback)
        else:
            return future
    return wrapper
The error page URI.
dataset/ETHPy150Open puentesarrin/asyncflux/asyncflux/util.py/asyncflux_coroutine--crossover with--dataset/ETHPy150Open lepture/flask-oauthlib/flask_oauthlib/provider/oauth1.py/OAuth1Provider.error_uri