Skip to content

Commit

Permalink
fix: throw error if no blobs
Browse files Browse the repository at this point in the history
  • Loading branch information
ratankaliani committed Sep 17, 2024
1 parent 0166eb1 commit 1652e04
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
Binary file modified elf/range-elf
Binary file not shown.
2 changes: 1 addition & 1 deletion scripts/prove/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ fn main() {
// Note: Don't comment this out, because the Docker program depends on the native program
// for range being built.
build_native_program(program);
// build_zkvm_program(program);
build_zkvm_program(program);
}

// build_zkvm_program("aggregation");
Expand Down
6 changes: 6 additions & 0 deletions utils/client/src/oracle/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,12 @@ impl InMemoryOracle {
}

println!("cycle-tracker-report-start: blob-verification");
// If there are no blobs, throw an error. Indicates that the blobs were not passed in, this occurs if the block is too recent.
// TODO: Look into why blobs are not being fetched for recent blocks.
if blobs.is_empty() {
return Err(anyhow!("No blobs found in oracle. This may be because the block is too recent."));
}

let commitments: Vec<Bytes48> =
blobs.keys().cloned().map(|blob| Bytes48::from_slice(&blob.0).unwrap()).collect_vec();
let kzg_proofs: Vec<Bytes48> = blobs
Expand Down

0 comments on commit 1652e04

Please sign in to comment.