Skip to content

Commit

Permalink
blob_ids() -> published_blob_ids()
Browse files Browse the repository at this point in the history
  • Loading branch information
andresilva91 committed Jul 8, 2024
1 parent a689665 commit 08a1327
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion linera-chain/src/data_types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ impl Block {
}

/// Returns all the blob IDs referred to in this block's operations.
pub fn blob_ids(&self) -> HashSet<BlobId> {
pub fn published_blob_ids(&self) -> HashSet<BlobId> {
let mut blob_ids = HashSet::new();
for operation in &self.operations {
if let Operation::System(SystemOperation::PublishBlob { blob_id }) = operation {
Expand Down
4 changes: 2 additions & 2 deletions linera-core/src/chain_worker/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ where
block: &Block,
hashed_blobs: &[HashedBlob],
) -> Result<Vec<BlobId>, WorkerError> {
let mut required_blob_ids = block.blob_ids();
let mut required_blob_ids = block.published_blob_ids();
// Find all certificates containing blobs used when executing this block.
for hashed_blob in hashed_blobs {
let blob_id = hashed_blob.id();
Expand Down Expand Up @@ -1087,7 +1087,7 @@ where
})
.collect::<HashSet<_>>();

let block_blob_ids = block.blob_ids();
let block_blob_ids = block.published_blob_ids();
let missing_blobs_from_oracles = block_blob_ids
.iter()
.filter(|block_blob_id| !blob_ids_in_oracle_records.contains(block_blob_id))
Expand Down
2 changes: 1 addition & 1 deletion linera-core/src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1441,7 +1441,7 @@ where
.local_node
.read_or_download_hashed_certificate_values(nodes.clone(), block.bytecode_locations())
.await?;
let hashed_blobs = self.read_local_blobs(block.blob_ids()).await?;
let hashed_blobs = self.read_local_blobs(block.published_blob_ids()).await?;
// Create the final block proposal.
let key_pair = self.key_pair().await?;
let proposal = if let Some(cert) = manager.requested_locked {
Expand Down
2 changes: 1 addition & 1 deletion linera-core/src/updater.rs
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ where
let required = match certificate.value() {
CertificateValue::ConfirmedBlock { executed_block, .. }
| CertificateValue::ValidatedBlock { executed_block, .. } => {
executed_block.block.blob_ids()
executed_block.block.published_blob_ids()
}
CertificateValue::Timeout { .. } => HashSet::new(),
};
Expand Down

0 comments on commit 08a1327

Please sign in to comment.