code: def config_search_paths(filename, search_dirs=None, **kwargs):
      """Get series of configuration base paths where Satpy configs are located."""
      if search_dirs is None:
          search_dirs = get_config_path_safe()[::-1]
  
      paths = [filename, os.path.basename(filename)]
      paths += [
          os.path.join(search_dir, filename)
          for search_dir in search_dirs
      ]
      paths += [os.path.join(PACKAGE_CONFIG_PATH, filename)]
      paths = [os.path.abspath(path) for path in paths]
  
      if kwargs.get("check_exists", True):
          paths = [x for x in paths if os.path.isfile(x)]
  
      paths = list(OrderedDict.fromkeys(paths))
      # flip the order of the list so builtins are loaded first
      return paths[::-1]
  
imports: from __future__ import annotations
  import ast
  import glob
  import logging
  import os
  import sys
  import tempfile
  from collections import OrderedDict
  from importlib.metadata import EntryPoint, entry_points
  from importlib.resources import files
  from typing import Iterable
  import appdirs
  from donfig import Config
  from satpy._compat import cache
label_desc: Use image node_id 5 for calling a global function with example usage: config_search_paths(filename, search_dirs) and returns: paths