Skip to content
This repository has been archived by the owner on Aug 21, 2024. It is now read-only.

Commit

Permalink
fix: clippy errors
Browse files Browse the repository at this point in the history
Signed-off-by: Dori Medini <dori@starkware.co>
  • Loading branch information
dorimedini-starkware committed Aug 12, 2024
1 parent 4448fcb commit 404ee63
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ test-case = "2.2.2"
thiserror = "1.0.37"

[workspace.lints.rust]
warnings = "deny"
future-incompatible = "deny"
nonstandard-style = "deny"
rust-2018-idioms = "deny"
unused = "deny"
unused = { level = "deny", priority = -1 }
warnings = "deny"
2 changes: 1 addition & 1 deletion crates/blockifier/src/fee/actual_cost.rs
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ impl<'a> ActualCostBuilder<'a> {
let bouncer_resources = actual_resources.clone();

// Add reverted steps to actual_resources' n_steps for correct fee charge.
*actual_resources.0.get_mut(&abi_constants::N_STEPS_RESOURCE.to_string()).unwrap() +=
*actual_resources.0.get_mut(abi_constants::N_STEPS_RESOURCE).unwrap() +=
self.n_reverted_steps;

let tx_info = &self.tx_context.tx_info;
Expand Down
2 changes: 1 addition & 1 deletion crates/blockifier/src/state/cached_state_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ fn global_contract_cache_is_used() {
let mut state = CachedState::new(DictStateReader::default(), global_cache.clone());

// Assert local cache is initialized empty even if global cache is not empty.
assert!(state.class_hash_to_class.get(&class_hash).is_none());
assert!(!state.class_hash_to_class.contains_key(&class_hash));

// Check state uses the global cache.
assert_eq!(state.get_compiled_contract_class(class_hash).unwrap(), contract_class);
Expand Down
1 change: 1 addition & 0 deletions crates/native_blockifier/src/py_validator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ pub struct PyValidator {

#[pymethods]
impl PyValidator {
#[allow(clippy::too_many_arguments)]
#[new]
#[pyo3(signature = (general_config, state_reader_proxy, next_block_info, validate_max_n_steps, invoke_max_n_steps, max_recursion_depth, global_contract_cache_size, max_nonce_for_validation_skip))]
pub fn create(
Expand Down

0 comments on commit 404ee63

Please sign in to comment.