code: def pytest_ignore_collect(collection_path: Path) -> bool:
      # Skip old nose code and the tests for it:
      # Note, that this is not only about executing tests but also importing those
      # files to begin with.
      if collection_path.name == "test_tests_utils.py":
          return True
      if collection_path.parts[:-3] == ("datalad", "tests", "utils.py"):
          return True
      # When pytest is told to run doctests, by default it will import every
      # source file in its search, but a number of datalad source file have
      # undesirable side effects when imported.  This hook should ensure that
      # only `test_*.py` files and `*.py` files containing doctests are imported
      # during test collection.
      if (
          collection_path.name.startswith("test_")
          or collection_path.is_dir()
      ):
          return False
      if collection_path.suffix != ".py":
          return True
      return not any(
          re.match(r"^\s*>>>", ln)
          for ln in collection_path.read_text("utf-8").splitlines()
      )
  
file_path: datalad/datalad/conftest.py
imports: import logging
  import os
  import re
  from contextlib import ExitStack
  from pathlib import Path
  from unittest.mock import patch
  import pytest
  from datalad.support.exceptions import CapturedException
  from datalad.utils import get_encoding_info, get_envvars_info, get_home_envvars
  from .None import cfg, ssh_manager
  from .log import lgr
label_desc: Use image node_id 3 for calling a global function with example usage: pytest_ignore_collect(collection_path) and returns: unknown, True, True, False, True