diff --git a/crates/batcher_types/Cargo.toml b/crates/batcher_types/Cargo.toml index 7532e2b6fb..97bf2bf328 100644 --- a/crates/batcher_types/Cargo.toml +++ b/crates/batcher_types/Cargo.toml @@ -5,7 +5,6 @@ edition.workspace = true license.workspace = true repository.workspace = true - [lints] workspace = true diff --git a/crates/consensus_manager/Cargo.toml b/crates/consensus_manager/Cargo.toml index bc40b8097a..cf76cc877b 100644 --- a/crates/consensus_manager/Cargo.toml +++ b/crates/consensus_manager/Cargo.toml @@ -5,7 +5,6 @@ edition.workspace = true license.workspace = true repository.workspace = true - [lints] workspace = true diff --git a/crates/mempool_test_utils/Cargo.toml b/crates/mempool_test_utils/Cargo.toml index 1996b75f36..8be25658c3 100644 --- a/crates/mempool_test_utils/Cargo.toml +++ b/crates/mempool_test_utils/Cargo.toml @@ -5,7 +5,8 @@ edition.workspace = true repository.workspace = true license.workspace = true -[features] +[lints] +workspace = true [dependencies] assert_matches.workspace = true diff --git a/crates/mempool_test_utils/src/starknet_api_test_utils.rs b/crates/mempool_test_utils/src/starknet_api_test_utils.rs index 3f685c86a6..c78c41da4f 100644 --- a/crates/mempool_test_utils/src/starknet_api_test_utils.rs +++ b/crates/mempool_test_utils/src/starknet_api_test_utils.rs @@ -275,7 +275,7 @@ impl MultiAccountTransactionGenerator { } /// Manages transaction generation for a single account. -/// Supports faulty transaction generation via [AccountTransactionGenerator::generate_raw]. +/// Supports faulty transaction generation via [AccountTransactionGenerator::generate_raw_invoke]. /// /// This struct provides methods to generate both default and fully customized transactions, /// with room for future extensions. diff --git a/crates/papyrus_base_layer/Cargo.toml b/crates/papyrus_base_layer/Cargo.toml index e15e16ddb1..55485e8d96 100644 --- a/crates/papyrus_base_layer/Cargo.toml +++ b/crates/papyrus_base_layer/Cargo.toml @@ -5,6 +5,9 @@ edition.workspace = true repository.workspace = true license-file.workspace = true +[lints] +workspace = true + [dependencies] alloy-contract.workspace = true alloy-dyn-abi.workspace = true diff --git a/crates/papyrus_common/Cargo.toml b/crates/papyrus_common/Cargo.toml index b396985e0c..f5105adc1b 100644 --- a/crates/papyrus_common/Cargo.toml +++ b/crates/papyrus_common/Cargo.toml @@ -25,3 +25,6 @@ assert_matches.workspace = true papyrus_test_utils.workspace = true pretty_assertions.workspace = true serde_json = { workspace = true, features = ["arbitrary_precision"] } + +[lints] +workspace = true diff --git a/crates/papyrus_common/src/python_json.rs b/crates/papyrus_common/src/python_json.rs index 8943bac9f0..220a874bb0 100644 --- a/crates/papyrus_common/src/python_json.rs +++ b/crates/papyrus_common/src/python_json.rs @@ -37,7 +37,7 @@ impl Formatter for PythonJsonFormatter { let mut buf = [0u16; 2]; for ch in fragment.chars() { if ch.is_ascii() { - writer.write_all(&[ch as u8])?; + writer.write_all(&[u8::try_from(ch).expect("ASCII fits in u8")])?; } else { let slice = ch.encode_utf16(&mut buf); for num in slice { diff --git a/crates/papyrus_config/Cargo.toml b/crates/papyrus_config/Cargo.toml index d3fb218a10..b798bc29ba 100644 --- a/crates/papyrus_config/Cargo.toml +++ b/crates/papyrus_config/Cargo.toml @@ -25,7 +25,5 @@ lazy_static.workspace = true papyrus_test_utils.workspace = true tempfile.workspace = true -[lints.rust] -# See [here](https://github.com/taiki-e/cargo-llvm-cov/issues/370) for a discussion on why this is -# needed (from rust 1.80). -unexpected_cfgs = { level = "warn", check-cfg = ['cfg(coverage_nightly)'] } +[lints] +workspace = true diff --git a/crates/papyrus_load_test/Cargo.toml b/crates/papyrus_load_test/Cargo.toml index 2e385ee200..b1054d6a2e 100644 --- a/crates/papyrus_load_test/Cargo.toml +++ b/crates/papyrus_load_test/Cargo.toml @@ -23,7 +23,5 @@ tokio.workspace = true lazy_static.workspace = true pretty_assertions.workspace = true -[lints.rust] -# See [here](https://github.com/taiki-e/cargo-llvm-cov/issues/370) for a discussion on why this is -# needed (from rust 1.80). -unexpected_cfgs = { level = "warn", check-cfg = ['cfg(coverage_nightly)'] } +[lints] +workspace = true diff --git a/crates/papyrus_monitoring_gateway/Cargo.toml b/crates/papyrus_monitoring_gateway/Cargo.toml index d2c713d4d7..96c85638c7 100644 --- a/crates/papyrus_monitoring_gateway/Cargo.toml +++ b/crates/papyrus_monitoring_gateway/Cargo.toml @@ -29,7 +29,5 @@ pretty_assertions.workspace = true starknet_client = { workspace = true, features = ["testing"] } tower = { workspace = true, features = ["util"] } -[lints.rust] -# See [here](https://github.com/taiki-e/cargo-llvm-cov/issues/370) for a discussion on why this is -# needed (from rust 1.80). -unexpected_cfgs = { level = "warn", check-cfg = ['cfg(coverage_nightly)'] } +[lints] +workspace = true diff --git a/crates/papyrus_network_types/Cargo.toml b/crates/papyrus_network_types/Cargo.toml index 1453ff0702..efcd0bf3fa 100644 --- a/crates/papyrus_network_types/Cargo.toml +++ b/crates/papyrus_network_types/Cargo.toml @@ -13,3 +13,6 @@ libp2p = { workspace = true, features = ["serde"] } papyrus_test_utils = { workspace = true, optional = true } rand_chacha = { workspace = true, optional = true } serde = { workspace = true, features = ["derive"] } + +[lints] +workspace = true diff --git a/crates/papyrus_proc_macros/Cargo.toml b/crates/papyrus_proc_macros/Cargo.toml index 80b42fe681..e2471eb39d 100644 --- a/crates/papyrus_proc_macros/Cargo.toml +++ b/crates/papyrus_proc_macros/Cargo.toml @@ -20,3 +20,6 @@ prometheus-parse.workspace = true [lib] proc-macro = true + +[lints] +workspace = true diff --git a/crates/sequencing/papyrus_consensus_orchestrator/Cargo.toml b/crates/sequencing/papyrus_consensus_orchestrator/Cargo.toml index 3d20bfad1e..dc15a7b8e0 100644 --- a/crates/sequencing/papyrus_consensus_orchestrator/Cargo.toml +++ b/crates/sequencing/papyrus_consensus_orchestrator/Cargo.toml @@ -27,3 +27,6 @@ papyrus_network = { workspace = true, features = ["testing"] } papyrus_storage = { workspace = true, features = ["testing"] } papyrus_test_utils.workspace = true test-case.workspace = true + +[lints] +workspace = true diff --git a/crates/starknet_client/Cargo.toml b/crates/starknet_client/Cargo.toml index ac344a3296..e326d8545f 100644 --- a/crates/starknet_client/Cargo.toml +++ b/crates/starknet_client/Cargo.toml @@ -54,7 +54,5 @@ papyrus_test_utils.workspace = true # `strum` is used by `EnumIter` which is used in this crate. ignored = ["rand", "rand_chacha", "strum"] -[lints.rust] -# See [here](https://github.com/taiki-e/cargo-llvm-cov/issues/370) for a discussion on why this is -# needed (from rust 1.80). -unexpected_cfgs = { level = "warn", check-cfg = ['cfg(coverage_nightly)'] } +[lints] +workspace = true