# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2021"
name = "sn_logging"
version = "0.2.25"
authors = ["MaidSafe Developers <dev@maidsafe.net>"]
description = "Safe Networking Logging"
homepage = "https://maidsafe.net"
documentation = "https://docs.rs/sn_node"
readme = "README.md"
license = "GPL-3.0"
repository = "https://github.com/maidsafe/safe_network"

[dependencies.chrono]
version = "~0.4.19"

[dependencies.dirs-next]
version = "~2.0.0"

[dependencies.file-rotate]
version = "0.7.3"

[dependencies.opentelemetry]
version = "0.20"
features = ["rt-tokio"]
optional = true

[dependencies.opentelemetry-otlp]
version = "0.13"
optional = true

[dependencies.opentelemetry-semantic-conventions]
version = "0.12.0"
optional = true

[dependencies.rand]
version = "~0.8.5"
features = ["small_rng"]
optional = true

[dependencies.serde]
version = "1.0.133"
features = [
    "derive",
    "rc",
]
optional = true

[dependencies.serde_json]
version = "1.0"
optional = true

[dependencies.sysinfo]
version = "0.29.0"
optional = true
default-features = false

[dependencies.thiserror]
version = "1.0.23"

[dependencies.tokio]
version = "1.32.0"
optional = true

[dependencies.tracing]
version = "~0.1.26"

[dependencies.tracing-appender]
version = "~0.2.0"

[dependencies.tracing-core]
version = "0.1.30"

[dependencies.tracing-opentelemetry]
version = "0.21"
optional = true

[dependencies.tracing-subscriber]
version = "0.3.16"
features = ["json"]

[dev-dependencies.color-eyre]
version = "~0.6"

[dev-dependencies.tracing-test]
version = "0.2.4"

[features]
otlp = [
    "opentelemetry",
    "opentelemetry-otlp",
    "opentelemetry-semantic-conventions",
    "tracing-opentelemetry",
    "rand/small_rng",
]
process-metrics = [
    "serde",
    "serde_json",
    "sysinfo",
    "tokio",
]
test-utils = []

[lints.clippy]
unicode_not_nfc = "warn"
uninlined_format_args = "warn"
unused_async = "warn"
unwrap_used = "warn"

[lints.rust]
arithmetic_overflow = "forbid"
mutable_transmutes = "forbid"
no_mangle_const_items = "forbid"
trivial_casts = "warn"
trivial_numeric_casts = "warn"
unknown_crate_types = "forbid"
unsafe_code = "forbid"
unused_extern_crates = "warn"
unused_import_braces = "warn"
