code: def run(main, *, debug=None):
      """Execute the coroutine and return the result.
  
      This function runs the passed coroutine, taking care of
      managing the asyncio event loop and finalizing asynchronous
      generators.
  
      This function cannot be called when another asyncio event loop is
      running in the same thread.
  
      If debug is True, the event loop will be run in debug mode.
  
      This function always creates a new event loop and closes it at the end.
      It should be used as a main entry point for asyncio programs, and should
      ideally only be called once.
  
      Example:
  
          async def main():
              await asyncio.sleep(1)
              print('hello')
  
          asyncio.run(main())
      """
      if events._get_running_loop() is not None:
          # fail fast with short traceback
          raise RuntimeError(
              "asyncio.run() cannot be called from a running event loop"
          )
  
      with Runner(debug=debug) as runner:
          return runner.run(main)
  
imports: import contextvars
  import enum
  import functools
  import threading
  import signal
  import sys
  from .None import coroutines
  from .None import events
  from .None import exceptions
  from .None import tasks
label_desc: Use image node_id 1 for calling a global function with example usage: run(main) and returns: runner