def on_finish(func, handler, args, kwargs):
    """
    Wrap the handler ``on_finish`` method to finish the Span for the
    given request, if available.
    """
    tracing = handler.settings.get('opentracing_tracing')
    tracing._finish_tracing(handler)

    return func(*args, **kwargs)
def on_finish ( func , handler , args , kwargs ) : tracing = handler . settings . get ( 'opentracing_tracing' ) tracing . _finish_tracing ( handler ) return func ( * args , ** kwargs )
Wrap the handler ``on_finish`` method to finish the Span for the
    given request, if available.