1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74
|
[package]
name = "libp2p-swarm"
edition = "2021"
rust-version = { workspace = true }
description = "The libp2p swarm"
version = "0.46.0"
authors = ["Parity Technologies <admin@parity.io>"]
license = "MIT"
repository = "https://github.com/libp2p/rust-libp2p"
keywords = ["peer-to-peer", "libp2p", "networking"]
categories = ["network-programming", "asynchronous"]
[dependencies]
either = "1.11.0"
fnv = "1.0"
futures = { workspace = true }
futures-timer = "3.0.3"
getrandom = { workspace = true, features = ["js"], optional = true } # Explicit dependency to be used in `wasm-bindgen` feature
web-time = { workspace = true }
libp2p-core = { workspace = true }
libp2p-identity = { workspace = true }
libp2p-swarm-derive = { workspace = true, optional = true }
lru = "0.12.3"
multistream-select = { workspace = true }
once_cell = "1.19.0"
rand = "0.8"
smallvec = "1.13.2"
tracing = { workspace = true }
wasm-bindgen-futures = { version = "0.4.42", optional = true }
[target.'cfg(not(any(target_os = "emscripten", target_os = "wasi", target_os = "unknown")))'.dependencies]
async-std = { version = "1.6.2", optional = true }
tokio = { workspace = true, features = ["rt"], optional = true }
[features]
macros = ["dep:libp2p-swarm-derive"]
tokio = ["dep:tokio"]
async-std = ["dep:async-std"]
wasm-bindgen = ["dep:wasm-bindgen-futures", "dep:getrandom"]
[dev-dependencies]
async-std = { version = "1.6.2", features = ["attributes"] }
either = "1.11.0"
futures = { workspace = true }
libp2p-identify = { path = "../protocols/identify" } # Using `path` here because this is a cyclic dev-dependency which otherwise breaks releasing.
libp2p-identity = { workspace = true, features = ["ed25519"] }
libp2p-kad = { path = "../protocols/kad" } # Using `path` here because this is a cyclic dev-dependency which otherwise breaks releasing.
libp2p-ping = { path = "../protocols/ping" } # Using `path` here because this is a cyclic dev-dependency which otherwise breaks releasing.
libp2p-plaintext = { path = "../transports/plaintext" } # Using `path` here because this is a cyclic dev-dependency which otherwise breaks releasing.
libp2p-swarm-derive = { path = "../swarm-derive" } # Using `path` here because this is a cyclic dev-dependency which otherwise breaks releasing.
libp2p-swarm-test = { path = "../swarm-test" } # Using `path` here because this is a cyclic dev-dependency which otherwise breaks releasing.
libp2p-yamux = { path = "../muxers/yamux" } # Using `path` here because this is a cyclic dev-dependency which otherwise breaks releasing.
quickcheck = { workspace = true }
criterion = { version = "0.5", features = ["async_tokio"] }
once_cell = "1.19.0"
trybuild = "1.0.95"
tokio = { workspace = true, features = ["time", "rt", "macros", "rt-multi-thread"] }
tracing-subscriber = { workspace = true, features = ["env-filter"] }
[[test]]
name = "swarm_derive"
required-features = ["macros"]
# Passing arguments to the docsrs builder in order to properly document cfg's.
# More information: https://docs.rs/about/builds#cross-compiling
[package.metadata.docs.rs]
all-features = true
[[bench]]
name = "connection_handler"
harness = false
[lints]
workspace = true
|