Skip to content

Commit

Permalink
fix(prover): change bucket for RAM permutation witnesses (#2672)
Browse files Browse the repository at this point in the history
## What ❔

<!-- What are the changes this PR brings about? -->
<!-- Example: This PR adds a PR template to the repo. -->
<!-- (For bigger PRs adding more context is appreciated) -->

## Why ❔

<!-- Why are these changes done? What goal do they contribute to? What
are the principles behind them? -->
<!-- Example: PR templates ensure PR reviewers, observers, and future
iterators are in context about the evolution of repos. -->

## Checklist

<!-- Check your PR fulfills the following items. -->
<!-- For draft PRs check the boxes as you complete them. -->

- [ ] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [ ] Tests for the changes have been added / updated.
- [ ] Documentation comments have been added / updated.
- [ ] Code has been formatted via `zk fmt` and `zk lint`.
  • Loading branch information
0xVolosnikov authored Aug 16, 2024
1 parent 8b8397a commit 8b4cbf4
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
1 change: 0 additions & 1 deletion core/lib/object_store/src/file.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ impl FileBackedObjectStore {
Bucket::ProofsFri,
Bucket::StorageSnapshot,
Bucket::TeeVerifierInput,
Bucket::RamPermutationCircuitQueueWitness,
] {
let bucket_path = format!("{base_dir}/{bucket}");
fs::create_dir_all(&bucket_path).await?;
Expand Down
2 changes: 0 additions & 2 deletions core/lib/object_store/src/raw.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ pub enum Bucket {
StorageSnapshot,
DataAvailability,
TeeVerifierInput,
RamPermutationCircuitQueueWitness,
}

impl Bucket {
Expand All @@ -40,7 +39,6 @@ impl Bucket {
Self::StorageSnapshot => "storage_logs_snapshots",
Self::DataAvailability => "data_availability",
Self::TeeVerifierInput => "tee_verifier_inputs",
Self::RamPermutationCircuitQueueWitness => "ram_permutation_witnesses",
}
}
}
Expand Down
6 changes: 5 additions & 1 deletion prover/crates/bin/witness_generator/src/basic_circuits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -668,7 +668,11 @@ async fn generate_witness(
.filter(|(circuit_id, _, _)| circuits_present.contains(circuit_id))
.collect();

futures::future::join_all(save_ram_queue_witness_handles).await;
let _: Vec<_> = futures::future::join_all(save_ram_queue_witness_handles)
.await
.into_iter()
.map(|result| result.expect("failed to save ram permutation queue witness"))
.collect();

scheduler_witness.previous_block_meta_hash = input.previous_batch_metadata.meta_hash.0;
scheduler_witness.previous_block_aux_hash = input.previous_batch_metadata.aux_hash.0;
Expand Down
2 changes: 1 addition & 1 deletion prover/crates/lib/prover_fri_types/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ pub struct RamPermutationQueueWitness {
}

impl StoredObject for RamPermutationQueueWitness {
const BUCKET: Bucket = Bucket::RamPermutationCircuitQueueWitness;
const BUCKET: Bucket = Bucket::ProverJobsFri;
type Key<'a> = RamPermutationQueueWitnessKey;

fn encode_key(key: Self::Key<'_>) -> String {
Expand Down

0 comments on commit 8b4cbf4

Please sign in to comment.