code: def pytest_make_collect_report(collector: Collector) -> CollectReport:
      call = CallInfo.from_call(
          lambda: list(collector.collect()), "collect"
      )
      longrepr: Union[
          None, Tuple[str, int, str], str, TerminalRepr
      ] = None
      if not call.excinfo:
          outcome: Literal["passed", "skipped", "failed"] = "passed"
      else:
          skip_exceptions = [Skipped]
          unittest = sys.modules.get("unittest")
          if unittest is not None:
              # Type ignored because unittest is loaded dynamically.
              skip_exceptions.append(unittest.SkipTest)  # type: ignore
          if isinstance(call.excinfo.value, tuple(skip_exceptions)):
              outcome = "skipped"
              r_ = collector._repr_failure_py(call.excinfo, "line")
              assert isinstance(r_, ExceptionChainRepr), repr(r_)
              r = r_.reprcrash
              assert r
              longrepr = (str(r.path), r.lineno, r.message)
          else:
              outcome = "failed"
              errorinfo = collector.repr_failure(call.excinfo)
              if not hasattr(errorinfo, "toterminal"):
                  assert isinstance(errorinfo, str)
                  errorinfo = CollectErrorRepr(errorinfo)
              longrepr = errorinfo
      result = call.result if not call.excinfo else None
      rep = CollectReport(collector.nodeid, outcome, longrepr, result)
      rep.call = call  # type: ignore # see collect_one_node
      return rep
  
imports: import bdb
  import dataclasses
  import os
  import sys
  from typing import Callable
  from typing import cast
  from typing import Dict
  from typing import Generic
  from typing import List
  from typing import Optional
  from typing import Tuple
  from typing import Type
  from typing import TYPE_CHECKING
  from typing import TypeVar
  from typing import Union
  from .reports import BaseReport
  from .reports import CollectErrorRepr
  from .reports import CollectReport
  from .reports import TestReport
  from _pytest import timing
  from _pytest._code.code import ExceptionChainRepr
  from _pytest._code.code import ExceptionInfo
  from _pytest._code.code import TerminalRepr
  from _pytest.compat import final
  from _pytest.config.argparsing import Parser
  from _pytest.deprecated import check_ispytest
  from _pytest.nodes import Collector
  from _pytest.nodes import Item
  from _pytest.nodes import Node
  from _pytest.outcomes import Exit
  from _pytest.outcomes import OutcomeException
  from _pytest.outcomes import Skipped
  from _pytest.outcomes import TEST_OUTCOME
label_desc: Use image node_id 17 for calling a global function with example usage: pytest_make_collect_report(collector) and returns: rep