(f=None, limit=None)
return stack
Replacement for traceback.extract_stack() that only does the
    necessary work for asyncio debug mode.
Replacement for traceback.extract_stack() that only does the
    necessary work for asyncio debug mode.
Replacement for traceback . extract_stack () that only does the necessary work for asyncio debug mode .
def extract_stack(f=None, limit=None):
    """Replacement for traceback.extract_stack() that only does the
    necessary work for asyncio debug mode.
    """
    if f is None:
        f = sys._getframe().f_back
    if limit is None:
        # Limit the amount of work to a reasonable amount, as extract_stack()
        # can be called for each coroutine and future in debug mode.
        limit = constants.DEBUG_STACK_DEPTH
    stack = traceback.StackSummary.extract(traceback.walk_stack(f),
                                           limit=limit,
                                           lookup_lines=False)
    stack.reverse()
    return stack
def extract_stack ( f = None , limit = None ) : if f is None : f = sys . _getframe ( ) . f_back if limit is None : # Limit the amount of work to a reasonable amount, as extract_stack() # can be called for each coroutine and future in debug mode. limit = constants . DEBUG_STACK_DEPTH stack = traceback . StackSummary . extract ( traceback . walk_stack ( f ) , limit = limit , lookup_lines = False ) stack . reverse ( ) return stack