code: def _asynciostacks(*args, **kwargs):  # pragma: no cover
      '''
      A signal handler used to print asyncio task stacks and thread stacks.
      '''
      print(80 * '*')
      print('Asyncio tasks stacks:')
      tasks = asyncio.all_tasks(_glob_loop)
      for task in tasks:
          task.print_stack()
      print(80 * '*')
      print('Faulthandler stack frames per thread:')
      faulthandler.dump_traceback()
      print(80 * '*'f _asynciostacks(*args, **kwargs):  # pragma: no cover
      '''
      A signal handler used to print asyncio task stacks and thread stacks.
      '''
      print(80 * '*')
      print('Asyncio tasks stacks:')
      tasks = asyncio.all_tasks(_glob_loop)
      for task in tasks:
          task.print_stack()
      print(80 * '*')
      print('Faulthandler stack frames per thread:')
      faulthandler.dump_traceback()
      print(80 * '*')
docs: A signal handler used to print asyncio task stacks and thread stacks.