Skip to content

Commit

Permalink
[refactor]: bump dependencies (#3981)
Browse files Browse the repository at this point in the history
Signed-off-by: Marin Veršić <[email protected]>
  • Loading branch information
mversic authored Oct 13, 2023
1 parent 067c8e1 commit b7e5bf0
Show file tree
Hide file tree
Showing 232 changed files with 1,103 additions and 2,011 deletions.
1,721 changes: 726 additions & 995 deletions Cargo.lock

Large diffs are not rendered by default.

234 changes: 73 additions & 161 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -58,112 +58,89 @@ iroha_trigger_derive = { version = "=2.0.0-pre-rc.19", path = "smart_contract/tr
test_network = { version = "=2.0.0-pre-rc.19", path = "core/test_network" }

proc-macro-error = "1.0.4"
proc-macro2 = "1.0.49"
proc-macro2 = "1.0.69"
syn = { package = "syn", version = "1.0.109", default-features = false }
syn2 = { package = "syn", version = "2.0.25", default-features = false }
quote = "1.0.23"
manyhow = { version = "0.5.1", features = ["darling"] }
darling = "0.20.1"
syn2 = { package = "syn", version = "2.0.38", default-features = false }
quote = "1.0.33"
manyhow = { version = "0.8.1", features = ["darling"] }
darling = "0.20.3"

futures = { version = "0.3.25", default-features = false }
async-stream = "0.3.3"
tokio = "1.23.0"
tokio-stream = "0.1.11"
tokio-tungstenite = "0.17.2"
futures = { version = "0.3.28", default-features = false }
async-stream = "0.3.5"
tokio = "1.33.0"
tokio-stream = "0.1.14"
tokio-tungstenite = "0.20.1"

crossbeam = "0.8.2"
crossbeam-queue = "0.3.8"
parking_lot = { version = "0.12.1" }

once_cell = "1.16.0"
tempfile = "3.3.0"
path-absolutize = "3.1.0"
once_cell = "1.18.0"
tempfile = "3.8.0"
path-absolutize = "3.1.1"
pathdiff = "0.2.1"
itertools = "0.10.5"
bytes = "1.4.0"
itertools = "0.11.0"
bytes = "1.5.0"

vergen = { version = "8.1.1", default-features = false }
trybuild = "1.0.73"
vergen = { version = "8.2.5", default-features = false }
trybuild = "1.0.85"
impls = "1.0.3"

base64 = { version = "0.13.1", default-features = false }
base64 = { version = "0.21.4", default-features = false }
hex = { version = "0.4.3", default-features = false }

fixnum = { version = "0.9.1", default-features = false }
url = "2.3.1"
fixnum = { version = "0.9.2", default-features = false }
url = "2.4.1"
prometheus = { version = "0.13.3", default-features = false }

clap = "4.2.1"
clap = "4.4.6"
owo-colors = "3.5.0"
supports-color = "2.0.0"
supports-color = "2.1.0"
inquire = "0.6.2"
spinoff = "0.7.0"
spinoff = "0.8.0"
duct = "0.13.6"

criterion = "0.3.6"
proptest = "1.0.0"
criterion = "0.5.1"
proptest = "1.3.1"
expect-test = "1.4.1"

eyre = "0.6.8"
color-eyre = "0.6.2"
thiserror = { version = "1.0.38", default-features = false }
thiserror = { version = "1.0.49", default-features = false }
displaydoc = { version = "0.2.4", default-features = false }

cfg-if = "1.0.0"
derive_more = { version = "0.99.17", default-features = false }
async-trait = "0.1.60"
strum = { version = "0.24.1", default-features = false }
async-trait = "0.1.73"
strum = { version = "0.25.0", default-features = false }
getset = "0.1.2"
hex-literal = "0.3.4"
hex-literal = "0.4.1"

ursa = "0.3.7"
aead = "0.3.2"

rand = "0.8.5"
warp = { version = "0.3.5", default-features = false }
wasmtime = "11.0.1"
warp = { version = "0.3.6", default-features = false }
wasmtime = "13.0.0"

tracing = "0.1.37"
tracing-core = "0.1.30"
tracing-subscriber = { version = "0.3.16", default-features = false }
tracing-core = "0.1.31"
tracing-subscriber = { version = "0.3.17", default-features = false }
tracing-futures = { version = "0.2.5", default-features = false }
tracing-bunyan-formatter = { version = "0.3.4", default-features = false }
tracing-bunyan-formatter = { version = "0.3.9", default-features = false }

dashmap = "5.4.0"
dashmap = "5.5.3"
rustc-hash = "1.1.0"

serde = { version = "1.0.151", default-features = false }
serde_json = { version = "1.0.91", default-features = false }
serde_yaml = "0.9.21"
serde_with = { version = "2.2.0", default-features = false }
parity-scale-codec = { version = "3.2.1", default-features = false }
serde = { version = "1.0.188", default-features = false }
serde_json = { version = "1.0.107", default-features = false }
serde_yaml = "0.9.25"
serde_with = { version = "3.3.0", default-features = false }
parity-scale-codec = { version = "3.6.5", default-features = false }
json5 = "0.4.1"

[workspace.lints]
rust.anonymous_parameters = "deny"

# lower the priority to allow overriding later
clippy.pedantic = { level = "deny", priority = -1 }
clippy.all = { level = "deny", priority = -1 }
clippy.dbg_macro = "deny"

# clippy.nursery = "deny"
clippy.debug_assert_with_mut_call = "deny"
clippy.derive_partial_eq_without_eq = "deny"
clippy.empty_line_after_outer_attr = "deny"
clippy.fallible_impl_from = "deny"
clippy.future_not_send = "deny"
clippy.iter_with_drain = "deny"
clippy.mutex_integer = "deny"
clippy.needless_collect = "deny"
clippy.path_buf_push_overwrite = "deny"
clippy.suboptimal_flops = "deny"
clippy.trailing_empty_array = "deny"
clippy.transmute_undefined_repr = "deny"
clippy.trivial_regex = "deny"
clippy.unused_peekable = "deny"
clippy.unused_rounding = "deny"

rust.future_incompatible = "deny"
rust.missing_copy_implementations = "deny"
rust.missing_docs = "deny"
Expand All @@ -180,116 +157,55 @@ rust.variant_size_differences = "deny"
rust.unused_tuple_struct_fields = "deny"
rust.explicit_outlives_requirements = "deny"
rust.non_ascii_idents = "deny"
rust.elided_lifetimes_in_paths = "allow"
rust.unknown_lints = "warn"
rust.single_use_lifetimes = "warn"
rust.unused_lifetimes = "warn"
# TODO: reenable
# rust.unreachable_pub = "deny"
# rust.unsafe_op_in_unsafe_fn = "deny"

# These are up to personal taste. We don't want these to be enabled ever.
clippy.string_add = "allow"
clippy.as_conversions = "allow"
clippy.else_if_without_else = "allow"
clippy.enum_glob_use = "allow"
clippy.exhaustive_enums = "allow"
clippy.exhaustive_structs = "allow"
clippy.implicit_return = "allow"
clippy.inconsistent_struct_constructor = "allow"
clippy.indexing_slicing = "allow"
clippy.arithmetic_side_effects = "allow"
clippy.let_underscore_must_use = "allow"
clippy.match_wildcard_for_single_variants = "allow"
clippy.missing_docs_in_private_items = "allow"
clippy.module_name_repetitions = "allow"
clippy.shadow_reuse = "allow"
clippy.shadow_same = "allow"
# lower the priority to allow overriding later
clippy.all = { level = "deny", priority = -1 }

# These are normally decisions, which need to be audited by a human.
clippy.unwrap_in_result = "allow"
clippy.expect_used = "allow"
clippy.unreachable = "allow"
clippy.wildcard_enum_match_arm = "allow"
# pedantic
clippy.pedantic = { level = "warn", priority = -1 }
clippy.match_wildcard_for_single_variants = "allow"
clippy.semicolon_if_nothing_returned = "allow"
clippy.wildcard_imports = "allow"
# Our preferred style.
clippy.non-ascii-literal = "allow"
clippy.std_instead_of_core = "allow"

# This lint could be useful in theory. The trade-off of making
# refactoring away from references difficult isn't worth it in all
# cases, so if it is enabled, it should be enabled locally.
clippy.pattern_type_mismatch = "allow"

# Style guide.
clippy.mod-module-files = "allow"
clippy.separated-literal-suffix = "allow"
# Most trybuild code triggers a false-positive.

# Not all public items should be inline. We only inline **trivial** functions.
clippy.missing_inline_in_public_items = "allow"

# --- Re-enable candidates -----

# Lots of false-positives.
clippy.self-named-module-files = "allow"
clippy.manual_let_else = "allow"

# We often need to shadow the name of the method to specialise.
# As soon as trait specialisation is stable we need to remove it.
clippy.same_name_method = "allow"
clippy.pub_use = "allow"

# Style guide candidate. Explicitly converting the return value to
# () is good for refactoring, and if there is necessary
# processing of the data returned by a function, it should
# **really** be marked as #[must_use]
clippy.semicolon_if_nothing_returned = "allow"

# This lint has way too many false-positives, so even enabling it
# as a warning is too much. Instead prefer adding explicit
# `#[deny]` directives
clippy.enum_glob_use = "allow"
clippy.module_name_repetitions = "allow"
clippy.must_use_candidate = "allow"

# Unstable and many false-positives
## https://rust-lang.github.io/rust-clippy/master/index.html#missing_const_for_fn
clippy.missing_const_for_fn = "allow"

# Too much affected code. Often impossible to apply suggestion on stable rust.
rust.elided_lifetimes_in_paths = "allow"

# This lint produces a lot of false positives. Recommend local #[deny] directives
clippy.use_self = "allow"

# We don't want to manually deny every `clippy.restriction.*` lint.
clippy.blanket-clippy-restriction-lints = "allow"

# A lot of false-positive.
clippy.partial_pub_fields = "allow"

# Should be enabled per trait impl rather than globally.
clippy.missing_trait_methods = "allow"

# We allow this and deny `clippy.semicolon_inside_block`.
clippy.semicolon_outside_block = "allow"

# It is debatable whether it's actually easier to read,
# additionally, not all patterns are covered by the inlined syntax
clippy.uninlined_format_args = "allow"
# restriction
clippy.dbg_macro = "deny"

rust.unknown_lints = "warn"
# these lints were duplicated, with `allow` taking precedence
# clippy.inconsistent_struct_constructor = "warn"
# clippy.match_wildcard_for_single_variants = "warn"
# clippy.arithmetic_side_effects = "warn"
# nursery
clippy.debug_assert_with_mut_call = "deny"
clippy.derive_partial_eq_without_eq = "deny"
clippy.empty_line_after_outer_attr = "deny"
clippy.fallible_impl_from = "deny"
clippy.future_not_send = "deny"
clippy.iter_with_drain = "deny"
clippy.mutex_integer = "deny"
clippy.needless_collect = "deny"
clippy.path_buf_push_overwrite = "deny"
clippy.suboptimal_flops = "deny"
clippy.trailing_empty_array = "deny"
clippy.transmute_undefined_repr = "deny"
clippy.trivial_regex = "deny"
clippy.unused_peekable = "deny"
clippy.unused_rounding = "deny"
clippy.option_if_let_else = "warn"
clippy.or_fun_call = "warn"
clippy.redundant_pub_crate = "warn"
clippy.string_lit_as_bytes = "warn"
clippy.suspicious_operation_groupings = "warn"
clippy.useless_let_if_seq = "warn"

# unstable
# rust.non_exhaustive_omitted_patterns = "warn"

rust.single_use_lifetimes = "warn"
rust.unused_lifetimes = "warn"
#cargo
clippy.redundant_feature_names = "deny"
clippy.wildcard_dependencies = "deny"

[workspace]
resolver = "2"
Expand Down Expand Up @@ -345,9 +261,5 @@ members = [

[profile.deploy]
inherits = "release"
opt-level = 3
debug = false
strip = "symbols"
debug-assertions = false
lto = true
incremental = false
2 changes: 1 addition & 1 deletion cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ thread-local-panic-hook = { version = "0.1.0", optional = true }
uuid = { version = "1.4.1", features = ["v4"] }

[dev-dependencies]
serial_test = "0.8.0"
serial_test = "2.0.0"

[build-dependencies]
iroha_wasm_builder = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion cli/derive/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
//! Crate with a proc macro for torii endpoint generation
#![allow(clippy::arithmetic_side_effects)] // We should remove `clippy::restriction`.
use proc_macro::TokenStream;
use proc_macro2::Span;
Expand Down
5 changes: 0 additions & 5 deletions cli/src/event.rs
Original file line number Diff line number Diff line change
@@ -1,11 +1,6 @@
//! Iroha is a quite dynamic system so many events can happen.
//! This module contains descriptions of such an events and
//! utility Iroha Special Instructions to work with them.
#![allow(
clippy::arithmetic_side_effects,
clippy::std_instead_of_core,
clippy::std_instead_of_alloc
)]
use futures::TryStreamExt;
use iroha_data_model::events::prelude::*;
use iroha_macro::error::ErrorTryFromEnum;
Expand Down
6 changes: 0 additions & 6 deletions cli/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,6 @@
//!
//! `Iroha` is the main instance of the peer program. `Arguments`
//! should be constructed externally: (see `main.rs`).
#![allow(
clippy::arithmetic_side_effects,
clippy::std_instead_of_core,
clippy::std_instead_of_alloc
)]
#[cfg(debug_assertions)]
use core::sync::atomic::{AtomicBool, Ordering};
use std::sync::Arc;
Expand Down Expand Up @@ -495,7 +490,6 @@ mod tests {

use super::*;

#[allow(clippy::panic, clippy::print_stdout)]
#[tokio::test]
#[serial]
async fn iroha_should_notify_on_panic() {
Expand Down
4 changes: 0 additions & 4 deletions cli/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
//! Iroha peer command-line interface.
#![allow(clippy::print_stdout)]
use std::env;

use color_eyre::eyre::WrapErr as _;
Expand Down Expand Up @@ -148,13 +147,11 @@ async fn main() -> Result<(), color_eyre::Report> {
Ok(())
}

#[allow(clippy::print_stdout)]
fn print_help(styling: &Styling) -> Result<(), std::io::Error> {
use std::io::Write;

let stdout = std::io::stdout();
let lock = stdout.lock();
#[allow(clippy::arithmetic_side_effects)] // No overflow
let mut buffer = std::io::BufWriter::with_capacity(1024 * REQUIRED_ENV_VARS.len(), lock);
writeln!(buffer, "{}", "Iroha 2".bold().green())?;
writeln!(buffer, "pass {} for this message", styling.or(&HELP_ARG))?;
Expand Down Expand Up @@ -206,7 +203,6 @@ as follows:",
Ok(())
}

#[allow(clippy::print_stdout)]
fn print_version(styling: &Styling) {
println!(
"{} {} (git hash {}) \n {}: {}",
Expand Down
1 change: 0 additions & 1 deletion cli/src/samples.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![allow(clippy::restriction)]
//! This module contains the sample configurations used for testing and benchmarking throghout Iroha.
use std::{collections::HashSet, path::Path, str::FromStr};

Expand Down
Loading

0 comments on commit b7e5bf0

Please sign in to comment.