code: def capture_traces(tracer):
      # tracer is a list
      task_id = get_task_id()
      if task_id is None:
          yield
          return
      tracers[task_id] = tracer
      yield
      del tracers[task_id]
  
file_path: datasette/datasette/tracer.py
imports: import asyncio
  from contextlib import contextmanager
  from contextvars import ContextVar
  from markupsafe import escape
  import time
  import json
  import traceback
label_desc: Use image node_id 4 for calling a global function with example usage: capture_traces(tracer) without return types