Skip to content

Commit 6a3a325

Browse files
Update strum to 0.27 (#8564)
#8547 Update our `strum` dependency to `0.27`. This unifies our strum dependencies and removes our duplication of `strum` (and by extension, `strum_macros`). Co-Authored-By: Mac L <mjladson@pm.me> Co-Authored-By: Michael Sproul <michaelsproul@users.noreply.github.com>
1 parent 49e1112 commit 6a3a325

File tree

6 files changed

+27
-55
lines changed

6 files changed

+27
-55
lines changed

Cargo.lock

Lines changed: 18 additions & 46 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ snap = "1"
235235
ssz_types = { version = "0.14.0", features = ["context_deserialize", "runtime_types"] }
236236
state_processing = { path = "consensus/state_processing" }
237237
store = { path = "beacon_node/store" }
238-
strum = { version = "0.24", features = ["derive"] }
238+
strum = { version = "0.27", features = ["derive"] }
239239
superstruct = "0.10"
240240
swap_or_not_shuffle = { path = "consensus/swap_or_not_shuffle" }
241241
syn = "1"

beacon_node/store/src/config.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use ssz::{Decode, Encode};
55
use ssz_derive::{Decode, Encode};
66
use std::io::{Read, Write};
77
use std::num::NonZeroUsize;
8-
use strum::{Display, EnumString, EnumVariantNames};
8+
use strum::{Display, EnumString, VariantNames};
99
use superstruct::superstruct;
1010
use types::EthSpec;
1111
use types::non_zero_usize::new_non_zero_usize;
@@ -267,7 +267,7 @@ mod test {
267267
}
268268

269269
#[derive(
270-
Debug, Clone, Copy, Eq, PartialEq, Serialize, Deserialize, Display, EnumString, EnumVariantNames,
270+
Debug, Clone, Copy, Eq, PartialEq, Serialize, Deserialize, Display, EnumString, VariantNames,
271271
)]
272272
#[strum(serialize_all = "lowercase")]
273273
pub enum DatabaseBackend {

database_manager/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ use store::{
2121
errors::Error,
2222
metadata::{CURRENT_SCHEMA_VERSION, SchemaVersion},
2323
};
24-
use strum::{EnumString, EnumVariantNames};
24+
use strum::{EnumString, VariantNames};
2525
use tracing::{info, warn};
2626
use types::{BeaconState, EthSpec, Slot};
2727

@@ -80,7 +80,7 @@ pub fn display_db_version<E: EthSpec>(
8080
}
8181

8282
#[derive(
83-
Debug, PartialEq, Eq, Clone, EnumString, Deserialize, Serialize, EnumVariantNames, ValueEnum,
83+
Debug, PartialEq, Eq, Clone, EnumString, Deserialize, Serialize, VariantNames, ValueEnum,
8484
)]
8585
pub enum InspectTarget {
8686
#[strum(serialize = "sizes")]

slasher/src/config.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use crate::Error;
22
use serde::{Deserialize, Serialize};
33
use std::num::NonZeroUsize;
44
use std::path::PathBuf;
5-
use strum::{Display, EnumString, EnumVariantNames};
5+
use strum::{Display, EnumString, VariantNames};
66
use types::non_zero_usize::new_non_zero_usize;
77
use types::{Epoch, EthSpec, IndexedAttestation};
88

@@ -59,7 +59,7 @@ pub struct DiskConfig {
5959
}
6060

6161
#[derive(
62-
Debug, Clone, Copy, PartialEq, Serialize, Deserialize, Display, EnumString, EnumVariantNames,
62+
Debug, Clone, Copy, PartialEq, Serialize, Deserialize, Display, EnumString, VariantNames,
6363
)]
6464
#[strum(serialize_all = "lowercase")]
6565
pub enum DatabaseBackend {

validator_client/beacon_node_fallback/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ use std::future::Future;
2020
use std::sync::Arc;
2121
use std::time::{Duration, Instant};
2222
use std::vec::Vec;
23-
use strum::EnumVariantNames;
23+
use strum::VariantNames;
2424
use task_executor::TaskExecutor;
2525
use tokio::{sync::RwLock, time::sleep};
2626
use tracing::{debug, error, warn};
@@ -752,7 +752,7 @@ async fn sort_nodes_by_health(nodes: &mut Vec<CandidateBeaconNode>) {
752752
}
753753

754754
/// Serves as a cue for `BeaconNodeFallback` to tell which requests need to be broadcasted.
755-
#[derive(Clone, Copy, Debug, PartialEq, Deserialize, Serialize, EnumVariantNames, ValueEnum)]
755+
#[derive(Clone, Copy, Debug, PartialEq, Deserialize, Serialize, VariantNames, ValueEnum)]
756756
#[strum(serialize_all = "kebab-case")]
757757
pub enum ApiTopic {
758758
None,

0 commit comments

Comments
 (0)