Skip to content

Commit

Permalink
chore(deps): make snafu a workspace dependency (#21798)
Browse files Browse the repository at this point in the history
* chore(deps): make snafu a workspace dependency

* fix deps
  • Loading branch information
pront authored Nov 14, 2024
1 parent 98b63cf commit 9f243aa
Show file tree
Hide file tree
Showing 12 changed files with 19 additions and 22 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ prost-types = { version = "0.12", default-features = false }
rand = { version = "0.8.5", default-features = false, features = ["small_rng"] }
serde_json = { version = "1.0.132", default-features = false, features = ["raw_value", "std"] }
serde = { version = "1.0.215", default-features = false, features = ["alloc", "derive", "rc"] }
snafu = { version = "0.7.5", default-features = false, features = ["futures", "std"] }
tokio = { version = "1.41.1", default-features = false, features = ["full"] }
toml = { version = "0.8.19", default-features = false, features = ["display", "parse"] }
tonic = { version = "0.11", default-features = false, features = ["transport", "codegen", "prost", "tls", "tls-roots", "gzip"] }
Expand All @@ -168,7 +169,7 @@ uuid.workspace = true
vrl.workspace = true
proptest = { workspace = true, optional = true }
proptest-derive = { workspace = true, optional = true }

snafu.workspace = true

# Internal libs
dnsmsg-parser = { path = "lib/dnsmsg-parser", optional = true }
Expand Down Expand Up @@ -349,7 +350,6 @@ rumqttc = { version = "0.24.0", default-features = false, features = ["use-rustl
seahash = { version = "4.1.0", default-features = false }
semver = { version = "1.0.23", default-features = false, features = ["serde", "std"], optional = true }
smallvec = { version = "1", default-features = false, features = ["union", "serde"] }
snafu = { version = "0.7.5", default-features = false, features = ["futures", "std"] }
snap = { version = "1.1.1", default-features = false }
socket2 = { version = "0.5.7", default-features = false }
stream-cancel = { version = "0.8.2", default-features = false }
Expand Down
2 changes: 1 addition & 1 deletion lib/codecs/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ serde.workspace = true
serde_with = { version = "3.11.0", default-features = false, features = ["std", "macros", "chrono_0_4"] }
serde_json.workspace = true
smallvec = { version = "1", default-features = false, features = ["union"] }
snafu = { version = "0.7.5", default-features = false, features = ["futures"] }
snafu.workspace = true
syslog_loose = { version = "0.21", default-features = false, optional = true }
tokio-util = { version = "0.7", default-features = false, features = ["codec"] }
tokio.workspace = true
Expand Down
2 changes: 1 addition & 1 deletion lib/dnsmsg-parser/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ license = "MIT"

[dependencies]
data-encoding = "2.6"
thiserror = "1.0"
hickory-proto = { version = "0.24", features = ["dnssec"] }
snafu.workspace = true

[dev-dependencies]
criterion = "0.5"
Expand Down
12 changes: 7 additions & 5 deletions lib/dnsmsg-parser/src/dns_message_parser.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ use hickory_proto::{
},
serialize::binary::{BinDecodable, BinDecoder},
};
use thiserror::Error;
use snafu::Snafu;

use crate::ede::{EDE, EDE_OPTION_CODE};

Expand All @@ -31,13 +31,15 @@ use super::dns_message::{
};

/// Error type for DNS message parsing
#[derive(Error, Debug)]
#[derive(Debug, Snafu)]
pub enum DnsMessageParserError {
#[error("Encountered error : {}", cause)]
#[snafu(display("Encountered error: {}", cause))]
SimpleError { cause: String },
#[error("Encountered error from TrustDns: {}", source.to_string())]

#[snafu(display("Encountered error from TrustDns: {}", source))]
TrustDnsError { source: ProtoError },
#[error("UTF8Error: {}", source)]

#[snafu(display("UTF8Error: {}", source))]
Utf8ParsingError { source: Utf8Error },
}

Expand Down
2 changes: 1 addition & 1 deletion lib/docs-renderer/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ publish = false
anyhow = { version = "1.0.93", default-features = false, features = ["std"] }
serde.workspace = true
serde_json.workspace = true
snafu = { version = "0.7.5", default-features = false }
snafu.workspace = true
tracing = { version = "0.1.34", default-features = false }
tracing-subscriber = { version = "0.3.18", default-features = false, features = ["ansi", "env-filter", "fmt", "json", "registry", "tracing-log"] }
vector-config = { path = "../vector-config" }
Expand Down
2 changes: 1 addition & 1 deletion lib/prometheus-parser/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ nom = "7.1.3"
num_enum = "0.7.3"
prost.workspace = true
prost-types.workspace = true
snafu = { version = "0.7" }
snafu.workspace = true
vector-common = { path = "../vector-common", features = ["btreemap"] }

[build-dependencies]
Expand Down
2 changes: 1 addition & 1 deletion lib/vector-buffers/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ paste = "1.0.15"
pin-project.workspace = true
rkyv = { version = "0.7.45", default-features = false, features = ["size_32", "std", "strict", "validation"] }
serde.workspace = true
snafu = { version = "0.7.5", default-features = false, features = ["std"] }
snafu.workspace = true
tokio-util = { version = "0.7.0", default-features = false }
tokio = { version = "1.41.1", default-features = false, features = ["rt", "macros", "rt-multi-thread", "sync", "fs", "io-util", "time"] }
tracing = { version = "0.1.34", default-features = false, features = ["attributes"] }
Expand Down
4 changes: 1 addition & 3 deletions lib/vector-common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,10 @@ byte_size_of = ["dep:bytes"]

conversion = [
"dep:bytes",
"dep:snafu",
]

encoding = [
"dep:nom",
"dep:snafu",
"btreemap"
]

Expand Down Expand Up @@ -56,7 +54,7 @@ ryu = { version = "1", default-features = false }
serde.workspace = true
serde_json.workspace = true
smallvec = { version = "1", default-features = false }
snafu = { version = "0.7", optional = true }
snafu.workspace = true
stream-cancel = { version = "0.8.2", default-features = false }
tokio = { version = "1.41.1", default-features = false, features = ["macros", "time"] }
tracing = { version = "0.1.34", default-features = false }
Expand Down
2 changes: 1 addition & 1 deletion lib/vector-config/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ num-traits = { version = "0.2.19", default-features = false }
serde.workspace = true
serde_json.workspace = true
serde_with = { version = "3.11.0", default-features = false, features = ["std"] }
snafu = { version = "0.7.5", default-features = false }
snafu.workspace = true
toml.workspace = true
tracing = { version = "0.1.34", default-features = false }
url = { version = "2.5.3", default-features = false, features = ["serde"] }
Expand Down
2 changes: 1 addition & 1 deletion lib/vector-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ serde.workspace = true
serde_json.workspace = true
serde_with = { version = "3.11.0", default-features = false, features = ["std", "macros"] }
smallvec = { version = "1", default-features = false, features = ["serde", "const_generics"] }
snafu = { version = "0.7.5", default-features = false }
snafu.workspace = true
socket2 = { version = "0.5.7", default-features = false }
tokio = { version = "1.41.1", default-features = false, features = ["net"] }
tokio-openssl = { version = "0.6.5", default-features = false }
Expand Down
5 changes: 1 addition & 4 deletions lib/vector-tap/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ colored = { version = "2.1.0", default-features = false }
futures.workspace = true
glob.workspace = true
serde_yaml = { version = "0.9.34", default-features = false }
snafu = { version = "0.7.5", default-features = false }
snafu.workspace = true
tokio = { version = "1.41.1", default-features = false, features = ["time"] }
tokio-stream = { version = "0.1.16", default-features = false, features = ["sync"] }
tokio-tungstenite = { version = "0.20.1", default-features = false }
Expand All @@ -33,6 +33,3 @@ chrono = { workspace = true }
portpicker = { path = "../portpicker" }
serde_json = { workspace = true }
tokio = { version = "1.41.1", default-features = false, features = ["test-util"] }



0 comments on commit 9f243aa

Please sign in to comment.