Skip to content

Commit

Permalink
cleanup some dependencies, fix prover build
Browse files Browse the repository at this point in the history
  • Loading branch information
Artemka374 committed Mar 20, 2024
1 parent 4467c0a commit a3d8adf
Show file tree
Hide file tree
Showing 14 changed files with 15 additions and 22 deletions.
5 changes: 1 addition & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions core/lib/dal/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ zksync_db_connection = { path = "../db_connection" }
itertools = "0.10.1"
thiserror = "1.0"
anyhow = "1.0"
url = "2"
prost = "0.12.1"
rand = "0.8"
tokio = { version = "1", features = ["full"] }
Expand All @@ -46,13 +45,9 @@ serde_json = "1.0"
bigdecimal = "0.3.0"
bincode = "1"
hex = "0.4"
once_cell = "1.7"
strum = { version = "0.24", features = ["derive"] }
tracing = "0.1"
chrono = { version = "0.4", features = ["serde"] }

[dev-dependencies]
assert_matches = "1.5.0"

[build-dependencies]
zksync_protobuf_build = { version = "0.1.0", git = "https://github.com/matter-labs/era-consensus.git", rev = "5329a809cfc06d4939fb5ece26c9ad1e1741c50a" }
4 changes: 4 additions & 0 deletions core/lib/dal/src/transactions_dal.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ impl TransactionsDal<'_, '_> {

let secs = (tx.received_timestamp_ms / 1000) as i64;
let nanosecs = ((tx.received_timestamp_ms % 1000) * 1_000_000) as u32;
#[allow(deprecated)]
let received_at = NaiveDateTime::from_timestamp_opt(secs, nanosecs).unwrap();

sqlx::query!(
Expand Down Expand Up @@ -177,6 +178,8 @@ impl TransactionsDal<'_, '_> {

let secs = (tx.received_timestamp_ms / 1000) as i64;
let nanosecs = ((tx.received_timestamp_ms % 1000) * 1_000_000) as u32;

#[allow(deprecated)]
let received_at = NaiveDateTime::from_timestamp_opt(secs, nanosecs).unwrap();

sqlx::query!(
Expand Down Expand Up @@ -297,6 +300,7 @@ impl TransactionsDal<'_, '_> {
let paymaster_input = tx.common_data.paymaster_params.paymaster_input;
let secs = (tx.received_timestamp_ms / 1000) as i64;
let nanosecs = ((tx.received_timestamp_ms % 1000) * 1_000_000) as u32;
#[allow(deprecated)]
let received_at = NaiveDateTime::from_timestamp_opt(secs, nanosecs).unwrap();
// Besides just adding or updating(on conflict) the record, we want to extract some info
// from the query below, to indicate what actually happened:
Expand Down
2 changes: 1 addition & 1 deletion core/lib/db_connection/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ categories = ["cryptography"]

[dependencies]
zksync_health_check = { path = "../health_check" }
zksync_types = { path = "../types" }

serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
Expand All @@ -36,3 +35,4 @@ tracing = "0.1"

[dev-dependencies]
assert_matches = "1.5.0"
zksync_basic_types = { path = "../basic_types" }
2 changes: 1 addition & 1 deletion core/lib/db_connection/src/instrument.rs
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ where

#[cfg(test)]
mod tests {
use zksync_types::{MiniblockNumber, H256};
use zksync_basic_types::{MiniblockNumber, H256};

use super::*;
use crate::{connection::ConnectionPool, utils::InternalMarker};
Expand Down
3 changes: 0 additions & 3 deletions prover/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion prover/prover_fri/src/prover_job_processor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ use zksync_prover_fri_types::{
};
use zksync_prover_fri_utils::fetch_next_circuit;
use zksync_queued_job_processor::{async_trait, JobProcessor};
use zksync_types::{basic_fri_types::CircuitIdRoundTuple, protocol::L1VerifierConfig};
use zksync_types::{basic_fri_types::CircuitIdRoundTuple, protocol_version::L1VerifierConfig};
use zksync_vk_setup_data_server_fri::{keystore::Keystore, GoldilocksProverSetupData};

use crate::{
Expand Down
2 changes: 1 addition & 1 deletion prover/prover_fri_utils/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ use zksync_prover_fri_types::{
};
use zksync_types::{
basic_fri_types::{AggregationRound, CircuitIdRoundTuple},
protocol::L1VerifierConfig,
protocol_version::L1VerifierConfig,
};

use crate::metrics::{CircuitLabels, PROVER_FRI_UTILS_METRICS};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ use zksync_prover_fri_types::circuit_definitions::{
circuit_definitions::recursion_layer::ZkSyncRecursionLayerStorageType,
};
use zksync_types::{
protocol::{L1VerifierConfig, VerifierParams},
protocol_version::{L1VerifierConfig, VerifierParams},
H256,
};

Expand Down
2 changes: 1 addition & 1 deletion prover/witness_generator/src/basic_circuits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ use zksync_types::{
basic_fri_types::{
AggregationRound, Eip4844Blobs, EIP_4844_BLOB_SIZE, MAX_4844_BLOBS_PER_BLOCK,
},
protocol::FriProtocolVersionId,
protocol_version::FriProtocolVersionId,
Address, L1BatchNumber, ProtocolVersionId, BOOTLOADER_ADDRESS, H256, U256,
};
use zksync_utils::{bytes_to_chunks, h256_to_u256, u256_to_h256};
Expand Down
2 changes: 1 addition & 1 deletion prover/witness_generator/src/leaf_aggregation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ use zksync_prover_fri_types::{
use zksync_prover_fri_utils::get_recursive_layer_circuit_id_for_base_layer;
use zksync_queued_job_processor::JobProcessor;
use zksync_types::{
basic_fri_types::AggregationRound, protocol::FriProtocolVersionId,
basic_fri_types::AggregationRound, protocol_version::FriProtocolVersionId,
prover_dal::LeafAggregationJobMetadata, L1BatchNumber,
};
use zksync_vk_setup_data_server_fri::keystore::Keystore;
Expand Down
2 changes: 1 addition & 1 deletion prover/witness_generator/src/node_aggregation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ use zksync_prover_fri_types::{
};
use zksync_queued_job_processor::JobProcessor;
use zksync_types::{
basic_fri_types::AggregationRound, protocol::FriProtocolVersionId,
basic_fri_types::AggregationRound, protocol_version::FriProtocolVersionId,
prover_dal::NodeAggregationJobMetadata, L1BatchNumber,
};
use zksync_vk_setup_data_server_fri::{keystore::Keystore, utils::get_leaf_vk_params};
Expand Down
2 changes: 1 addition & 1 deletion prover/witness_generator/src/scheduler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ use zksync_prover_fri_types::{
use zksync_queued_job_processor::JobProcessor;
use zksync_types::{
basic_fri_types::{AggregationRound, FinalProofIds},
protocol::FriProtocolVersionId,
protocol_version::FriProtocolVersionId,
L1BatchNumber,
};
use zksync_vk_setup_data_server_fri::{keystore::Keystore, utils::get_leaf_vk_params};
Expand Down
2 changes: 1 addition & 1 deletion prover/witness_vector_generator/src/generator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ use zksync_prover_fri_utils::{
};
use zksync_queued_job_processor::JobProcessor;
use zksync_types::{
basic_fri_types::CircuitIdRoundTuple, protocol::L1VerifierConfig,
basic_fri_types::CircuitIdRoundTuple, protocol_version::L1VerifierConfig,
prover_dal::GpuProverInstanceStatus,
};
use zksync_vk_setup_data_server_fri::keystore::Keystore;
Expand Down

0 comments on commit a3d8adf

Please sign in to comment.