def _get_app_and_run_info(
    attributes: Dict[str, Any], resource_attributes: Dict[str, Any]
) -> Tuple[str, str, str, str]:
    """Get app info from attributes.

    Args:
        attributes: Span attributes of record root.
        resource_attributes: Resource attributes of record root.

    Returns:
        Tuple of: app name, app version, and app id, run name.
    """

    def get_value(keys: List[str]) -> Optional[str]:
        for key in keys:
            for attr in [resource_attributes, attributes]:
                if key in attr:
                    return attr[key]
        return None

    app_name = get_value([
        f"snow.{BASE_SCOPE}.object.name",
        ResourceAttributes.APP_NAME,
    ])
    app_version = get_value([
        f"snow.{BASE_SCOPE}.object.version.name",
        ResourceAttributes.APP_VERSION,
    ])
    app_id = get_value([ResourceAttributes.APP_ID])
    run_name = get_value([
        f"snow.{BASE_SCOPE}.run.name",
        SpanAttributes.RUN_NAME,
    ])
    return app_name, app_version, app_id, run_name
Get app info from attributes.

    Args:
        attributes: Span attributes of record root.
        resource_attributes: Resource attributes of record root.

    Returns:
        Tuple of: app name, app version, and app id, run name.
    
src/feedback/trulens/feedback/computer.py