class_docstr: A super-simple branch coverage tracer.
class_docstr_tok: ["A","super-simple","branch","coverage","tracer","."]
code: def __enter__(self):
      if sys.version_info[:2] < (3, 12):
          assert sys.gettrace() is None  # caller checks in core.py
          sys.settrace(self.trace)
          return self
  
      sys.monitoring.use_tool_id(MONITORING_TOOL_ID, "scrutineer")
      for event, callback_name in MONITORING_EVENTS.items():
          sys.monitoring.set_events(MONITORING_TOOL_ID, event)
          callback = getattr(self, callback_name)
          sys.monitoring.register_callback(
              MONITORING_TOOL_ID, event, callback
          )
  
      return self
  
imports: import functools
  import os
  import subprocess
  import sys
  import types
  from collections import defaultdict
  from functools import lru_cache, reduce
  from os import sep
  from pathlib import Path
  from typing import TYPE_CHECKING, Dict, List, Optional, Set, Tuple
  from hypothesis._settings import Phase, Verbosity
  from hypothesis.internal.escalation import is_hypothesis_file
label_desc: Use image node_id 4 for calling the Tracer obj's underlying member method code with example usage: obj.__enter__() and returns: self, self