Skip to content
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
444 changes: 174 additions & 270 deletions Cargo.lock

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ cid = { version = "0.11", default-features = false, features = ["std"] }
flume = "0.11"
futures = "0.3"
get-size2 = { version = "0.7", features = ["derive", "hashbrown"] }
hashlink = "0.10"
hashlink = "0.11"
libp2p = { version = "0.56", default-features = false }
libp2p-swarm-test = { version = "0.6", default-features = false, features = ["tokio"] }
multihash-codetable = { version = "0.1", features = ["blake2b", "blake2s", "blake3", "sha2", "sha3", "strobe"] }
Expand Down Expand Up @@ -224,7 +224,7 @@ walkdir = "2"
zstd = "0.13"

# optional dependencies
console-subscriber = { version = "0.4", features = ["parking_lot"], optional = true }
console-subscriber = { version = "0.5", features = ["parking_lot"], optional = true }
tikv-jemallocator = { version = "0.6", optional = true }
tracing-chrome = { version = "0.7", optional = true }
tracing-loki = { version = "0.2", default-features = false, features = ["compat-0-2-1", "rustls"], optional = true }
Expand All @@ -233,7 +233,7 @@ tracing-loki = { version = "0.2", default-features = false, features = ["compat-
termios = "0.3"

[dev-dependencies]
ariadne = "0.5"
ariadne = "0.6"
assert_cmd = "2"
bimap = "0.6"
cargo_metadata = "0.23"
Expand All @@ -254,7 +254,7 @@ predicates = "3"
proc-macro2 = { version = "1", default-features = false, features = ["span-locations"] }
quickcheck = "1"
quickcheck_macros = "1"
ra_ap_syntax = "0.0.301"
ra_ap_syntax = "0.0.304"
regex-automata = "0.4"
serial_test = "3"
syn = { version = "2", default-features = false, features = ["full", "parsing", "visit", "printing", "extra-traits"] }
Expand Down
2 changes: 1 addition & 1 deletion rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[toolchain]
channel = "1.90.0"
channel = "1.91.0"
components = ["clippy", "llvm-tools-preview", "rustfmt"]
11 changes: 4 additions & 7 deletions src/networks/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -138,9 +138,12 @@ impl NetworkChain {
}

/// Defines the meaningful heights of the protocol.
#[derive(Debug, Display, Clone, Copy, Serialize, Deserialize, PartialEq, Eq, Hash, EnumIter)]
#[derive(
Debug, Default, Display, Clone, Copy, Serialize, Deserialize, PartialEq, Eq, Hash, EnumIter,
)]
#[cfg_attr(test, derive(derive_quickcheck_arbitrary::Arbitrary))]
pub enum Height {
#[default]
Breeze,
Smoke,
Ignition,
Expand Down Expand Up @@ -178,12 +181,6 @@ pub enum Height {
GoldenWeek,
}

impl Default for Height {
fn default() -> Height {
Self::Breeze
}
}

impl From<Height> for NetworkVersion {
fn from(height: Height) -> NetworkVersion {
match height {
Expand Down
13 changes: 5 additions & 8 deletions src/rpc/methods/sync/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,14 @@ use crate::lotus_json::lotus_json_with_self;
use schemars::JsonSchema;
use serde::{Deserialize, Serialize};

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq, JsonSchema)]
#[derive(Debug, Default, Clone, Serialize, Deserialize, PartialEq, Eq, JsonSchema)]
#[serde(rename_all = "PascalCase")]
pub enum SnapshotProgressState {
#[default]
Initializing,
InProgress { message: String },
InProgress {
message: String,
},
Completed,
NotRequired,
}
Expand All @@ -38,12 +41,6 @@ impl SnapshotProgressState {
}
}

impl Default for SnapshotProgressState {
fn default() -> Self {
Self::Initializing
}
}

impl std::fmt::Display for SnapshotProgressState {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
Expand Down
2 changes: 2 additions & 0 deletions src/rpc/reflect/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ pub enum Permission {
#[repr(u8)]
#[derive(
Debug,
Default,
Clone,
Copy,
Hash,
Expand All @@ -136,6 +137,7 @@ pub enum ApiPaths {
V0 = 0b00000001,
/// Only expose this method on `/rpc/v1`
#[strum(ascii_case_insensitive)]
#[default]
V1 = 0b00000010,
/// Only expose this method on `/rpc/v2`
#[strum(ascii_case_insensitive)]
Expand Down
9 changes: 2 additions & 7 deletions src/utils/misc/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@ mod logo;
pub use logo::*;
pub mod env;

#[derive(Debug, Clone, PartialEq, Eq, strum::EnumString)]
#[derive(Debug, Default, Clone, PartialEq, Eq, strum::EnumString)]
#[strum(serialize_all = "kebab-case")]
pub enum LoggingColor {
Always,
#[default]
Auto,
Never,
}
Expand All @@ -26,9 +27,3 @@ impl LoggingColor {
}
}
}

impl Default for LoggingColor {
fn default() -> Self {
Self::Auto
}
}
8 changes: 4 additions & 4 deletions tests/common/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,19 @@

use std::path::PathBuf;

use assert_cmd::Command;
use assert_cmd::{Command, cargo::cargo_bin_cmd};
use tempfile::TempDir;

pub fn cli() -> Command {
Command::cargo_bin("forest-cli").unwrap()
cargo_bin_cmd!("forest-cli")
}

pub fn tool() -> Command {
Command::cargo_bin("forest-tool").unwrap()
cargo_bin_cmd!("forest-tool")
}

pub fn daemon() -> Command {
Command::cargo_bin("forest").unwrap()
cargo_bin_cmd!("forest")
}

pub trait CommonArgs {
Expand Down
Loading