def get_missing_frameworks(descriptor, environment, yml_file):
    """
    Returns a list of missing frameworks from a given environment based on the
    list of dependencies returned by a bundle descriptor.

    :param descriptor: The bundle for which missing dependencies will be searched.
    :param environment: The environment to search in
    :param yml_file: The yml file inside the environment to start the search from.

    :returns: A list of dictionaries, each with a name and a version key, e.g.
        [{'version': 'v0.1.0', 'name': 'tk-framework-widget'}]
    """
    required_frameworks = descriptor.required_frameworks
    current_framework_instances = environment.find_framework_instances_from(yml_file) 

    if len(required_frameworks) == 0:
        return []

    missing_fws = []
    for fw in required_frameworks:
        # the required_frameworks structure in the info.yml
        # is a list of dicts, each dict having a name and a version key
        name = fw.get("name")
        version = fw.get("version")

        # find it by naming convention based on the instance name
        desired_fw_instance = "%s_%s" % (name, version)

        if desired_fw_instance not in current_framework_instances:
            missing_fws.append(fw)

    return missing_fws