def METHOD_NAME(name, path_eval=False):
    """Returns value of specified configuration setting."""
    default_value = DEFAULTS[name]
    result = os.getenv(name, default_value)
    # split on ':' and find the first suitable path
    if (
        path_eval
        and isinstance(result, str)
        and isinstance(default_value, str)
        and not isinstance(default_value, bool)
    ):
        locations = result.split(":")
        result = None
        for loc in locations:
            if os.path.isfile(loc):
                result = loc
                break
        if result is None:
            result = locations[0]
    # Check for setting that expects a boolean result.
    if isinstance(default_value, bool):
        return _cast_bool(result)
    # Special default for FAUCET_EVENT_SOCK.
    if name == "FAUCET_EVENT_SOCK":
        if result == "0":
            return ""
        if _cast_bool(result):
            return _PREFIX + "/var/run/faucet/faucet.sock"
    if name == "FAUCET_EVENT_SOCK_HEARTBEAT":
        if result == "0":
            return 0
    return result