pub fn entries_with_proofs(
        &self,
        version: u64,
        leaf_keys: &[Key],
    ) -> Result<Vec<TreeEntryWithProof>, NoVersionError> {
        let mut hasher = HasherWithStats::new(&self.hasher);
        let _profiling_guard = self
            .db
            .start_profiling(ProfiledTreeOperation::GetEntriesWithProofs);
        load_and_transform_entries(
            &self.db,
            version,
            leaf_keys,
            |patch_set, &leaf_key, longest_prefix| {
                let (leaf, merkle_path) =
                    patch_set.create_proof(&mut hasher, leaf_key, longest_prefix, 0);
                let value = leaf
                    .as_ref()
                    .map_or_else(ValueHash::zero, |leaf| leaf.value_hash);
                TreeEntry {
                    key: leaf_key,
                    value,
                    leaf_index: leaf.map_or(0, |leaf| leaf.leaf_index),
                }
                .with_merkle_path(merkle_path.into_inner())
            },
        )
    }
Reads entries together with Merkle proofs with the specified keys from the tree. The entries are returned
in the same order as requested.

# Errors

Returns an error if the tree `version` is missing.
core/lib/merkle_tree/src/getters.rs