Skip to content

refactor: serde trait file name #133

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ use crate::patricia_merkle_tree::node_data::inner_node::{
BinaryData, EdgeData, EdgePath, EdgePathLength, NodeData, PathToBottom,
};
use crate::patricia_merkle_tree::node_data::leaf::{LeafData, LeafDataImpl};
use crate::storage::db_object::{DBObject, Deserializable};
use crate::storage::errors::{DeserializationError, SerializationError};
use crate::storage::serde_trait::{DBObject, Deserializable};
use crate::storage::storage_trait::{StorageKey, StoragePrefix, StorageValue};

use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ use crate::patricia_merkle_tree::types::NodeIndex;
use crate::patricia_merkle_tree::updated_skeleton_tree::hash_function::TreeHashFunction;
use crate::patricia_merkle_tree::updated_skeleton_tree::node::UpdatedSkeletonNode;
use crate::patricia_merkle_tree::updated_skeleton_tree::tree::UpdatedSkeletonTree;
use crate::storage::serde_trait::DBObject;
use crate::storage::db_object::DBObject;
use crate::storage::storage_trait::StorageKey;
use crate::storage::storage_trait::StorageValue;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use crate::felt::Felt;
use crate::hash::hash_trait::HashOutput;
use crate::patricia_merkle_tree::filled_tree::node::{ClassHash, Nonce};
use crate::patricia_merkle_tree::types::NodeIndex;
use crate::storage::serde_trait::DBObject;
use crate::storage::db_object::DBObject;

pub trait LeafData: Clone + Sync + Send + DBObject {
/// Returns true if leaf is empty.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
use crate::patricia_merkle_tree::node_data::leaf::{ContractState, LeafDataImpl};
use crate::storage::serde_trait::DBObject;
use crate::storage::db_object::DBObject;
use crate::storage::storage_trait::{StoragePrefix, StorageValue};

impl DBObject for LeafDataImpl {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ use crate::patricia_merkle_tree::types::TreeHeight;
use crate::patricia_merkle_tree::{
original_skeleton_tree::node::OriginalSkeletonNode, types::NodeIndex,
};
use crate::storage::db_object::Deserializable;
use crate::storage::errors::StorageError;
use crate::storage::serde_trait::Deserializable;
use crate::storage::storage_trait::create_db_key;
use crate::storage::storage_trait::Storage;
use crate::storage::storage_trait::StorageKey;
Expand Down
2 changes: 1 addition & 1 deletion crates/committer/src/storage.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
pub mod db_object;
pub mod errors;
pub mod map_storage;
pub mod serde_trait;
pub mod storage_trait;
2 changes: 1 addition & 1 deletion crates/committer_cli/src/tests/python_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ use committer::patricia_merkle_tree::node_data::leaf::{ContractState, LeafDataIm
use committer::patricia_merkle_tree::updated_skeleton_tree::hash_function::{
CONTRACT_CLASS_LEAF_V0, CONTRACT_STATE_HASH_VERSION,
};
use committer::storage::db_object::DBObject;
use committer::storage::errors::{DeserializationError, SerializationError};
use committer::storage::map_storage::MapStorage;
use committer::storage::serde_trait::DBObject;
use committer::storage::storage_trait::{Storage, StorageKey, StorageValue};
use std::fmt::Debug;
use std::{collections::HashMap, io};
Expand Down
Loading