code: def _find_connection_file(connection_file, profile=None):
      """Return the absolute path for a connection file
  
      - If nothing specified, return current Kernel's connection file
      - If profile specified, show deprecation warning about finding connection files in profiles
      - Otherwise, call jupyter_client.find_connection_file
      """
      if connection_file is None:
          # get connection file from current kernel
          return get_connection_file()
      else:
          # connection file specified, allow shortnames:
          if profile is not None:
              warnings.warn(
                  "Finding connection file by profile is deprecated.",
                  DeprecationWarning,
                  stacklevel=3,
              )
              return find_connection_file(
                  connection_file, profile=profile
              )
          else:
              return jupyter_client.find_connection_file(
                  connection_file
              )
  
file_path: catboost/contrib/python/ipykernel/py2/ipykernel/connect.py
imports: from __future__ import absolute_import
  import json
  import sys
  from subprocess import Popen, PIPE
  import warnings
  from IPython.core.profiledir import ProfileDir
  from IPython.paths import get_ipython_dir
  from ipython_genutils.path import filefind
  from ipython_genutils.py3compat import str_to_bytes, PY3
  import jupyter_client
  from jupyter_client import write_connection_file
label_desc: Use image node_id 3 for calling a global function with example usage: _find_connection_file(connection_file, profile) and returns: get_connection_file, find_connection_file, jupyter_client