From 95c85984c3d180df762a2c7d164951214d4b8ab2 Mon Sep 17 00:00:00 2001 From: Darius Date: Fri, 17 Jan 2025 06:33:08 -0600 Subject: [PATCH 1/5] chore: introduce libp2p-webrtc-websys behind webrtc-websys feature flag. --- Cargo.lock | 1 + libp2p/CHANGELOG.md | 4 ++++ libp2p/Cargo.toml | 2 ++ libp2p/src/lib.rs | 3 +++ 4 files changed, 10 insertions(+) diff --git a/Cargo.lock b/Cargo.lock index a811dcc6de9..285a327677e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2690,6 +2690,7 @@ dependencies = [ "libp2p-tls", "libp2p-uds", "libp2p-upnp", + "libp2p-webrtc-websys", "libp2p-websocket", "libp2p-websocket-websys", "libp2p-webtransport-websys", diff --git a/libp2p/CHANGELOG.md b/libp2p/CHANGELOG.md index 91f1b5628f8..10ce732cd13 100644 --- a/libp2p/CHANGELOG.md +++ b/libp2p/CHANGELOG.md @@ -1,3 +1,7 @@ +## 0.55.1 +- Introduce `libp2p-webrtc-websys` behind `webrtc-websys` feature flag. + See [PR XXXX](https://github.com/libp2p/rust-libp2p/pull/XXXX) + ## 0.55.0 - Raise MSRV to 1.83.0. diff --git a/libp2p/Cargo.toml b/libp2p/Cargo.toml index 39d01a5c5c7..ab04a9f4f37 100644 --- a/libp2p/Cargo.toml +++ b/libp2p/Cargo.toml @@ -83,6 +83,7 @@ tls = ["dep:libp2p-tls"] tokio = [ "libp2p-swarm/tokio", "libp2p-mdns?/tokio", "libp2p-tcp?/tokio", "libp2p-dns?/tokio", "libp2p-quic?/tokio", "libp2p-upnp?/tokio"] uds = ["dep:libp2p-uds"] wasm-bindgen = [ "futures-timer/wasm-bindgen", "getrandom/js", "libp2p-swarm/wasm-bindgen", "libp2p-gossipsub?/wasm-bindgen"] +webrtc-websys = ['dep:libp2p-webrtc-websys'] websocket-websys = ["dep:libp2p-websocket-websys"] websocket = ["dep:libp2p-websocket"] webtransport-websys = ["dep:libp2p-webtransport-websys"] @@ -117,6 +118,7 @@ libp2p-relay = { workspace = true, optional = true } libp2p-rendezvous = { workspace = true, optional = true } libp2p-request-response = { workspace = true, optional = true } libp2p-swarm = { workspace = true } +libp2p-webrtc-websys = { workspace = true, optional = true } libp2p-websocket-websys = { workspace = true, optional = true } libp2p-webtransport-websys = { workspace = true, optional = true } libp2p-yamux = { workspace = true, optional = true } diff --git a/libp2p/src/lib.rs b/libp2p/src/lib.rs index 47e1142d0e9..80b5880f6d5 100644 --- a/libp2p/src/lib.rs +++ b/libp2p/src/lib.rs @@ -123,6 +123,9 @@ pub use libp2p_uds as uds; #[cfg(not(target_arch = "wasm32"))] #[doc(inline)] pub use libp2p_upnp as upnp; +#[cfg(feature = "webrtc-websys")] +#[doc(inline)] +pub use libp2p_webrtc_websys as webrtc_websys; #[cfg(feature = "websocket")] #[cfg(not(target_arch = "wasm32"))] #[doc(inline)] From f945d594cae315fc0fe4f2fdfabf23853b33780e Mon Sep 17 00:00:00 2001 From: Darius Date: Fri, 17 Jan 2025 06:36:40 -0600 Subject: [PATCH 2/5] chore: bump version --- Cargo.lock | 2 +- Cargo.toml | 2 +- libp2p/Cargo.toml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 285a327677e..3eaa52e1a11 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2654,7 +2654,7 @@ checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a" [[package]] name = "libp2p" -version = "0.55.0" +version = "0.55.1" dependencies = [ "async-std", "bytes", diff --git a/Cargo.toml b/Cargo.toml index 4b92b086326..589e485a086 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -72,7 +72,7 @@ resolver = "2" rust-version = "1.83.0" [workspace.dependencies] -libp2p = { version = "0.55.0", path = "libp2p" } +libp2p = { version = "0.55.1", path = "libp2p" } libp2p-allow-block-list = { version = "0.5.0", path = "misc/allow-block-list" } libp2p-autonat = { version = "0.14.0", path = "protocols/autonat" } libp2p-connection-limits = { version = "0.5.0", path = "misc/connection-limits" } diff --git a/libp2p/Cargo.toml b/libp2p/Cargo.toml index ab04a9f4f37..9bfa5c66363 100644 --- a/libp2p/Cargo.toml +++ b/libp2p/Cargo.toml @@ -3,7 +3,7 @@ name = "libp2p" edition = "2021" rust-version = { workspace = true } description = "Peer-to-peer networking library" -version = "0.55.0" +version = "0.55.1" authors = ["Parity Technologies "] license = "MIT" repository = "https://github.com/libp2p/rust-libp2p" From 4f99fa79b16d770dd875857337f06714ebbeea52 Mon Sep 17 00:00:00 2001 From: Darius Date: Fri, 17 Jan 2025 06:40:11 -0600 Subject: [PATCH 3/5] chore: add feature to `full` feature --- libp2p/Cargo.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/libp2p/Cargo.toml b/libp2p/Cargo.toml index 9bfa5c66363..4cfd2957a2a 100644 --- a/libp2p/Cargo.toml +++ b/libp2p/Cargo.toml @@ -44,6 +44,7 @@ full = [ "tokio", "uds", "wasm-bindgen", + "webrtc-websys", "websocket-websys", "websocket", "webtransport-websys", From 8b499f43f619c66ae733d667ade0bea792795e53 Mon Sep 17 00:00:00 2001 From: Darius Clark Date: Fri, 17 Jan 2025 06:54:48 -0600 Subject: [PATCH 4/5] Update libp2p/CHANGELOG.md --- libp2p/CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libp2p/CHANGELOG.md b/libp2p/CHANGELOG.md index 10ce732cd13..fdc2e541159 100644 --- a/libp2p/CHANGELOG.md +++ b/libp2p/CHANGELOG.md @@ -1,6 +1,6 @@ ## 0.55.1 - Introduce `libp2p-webrtc-websys` behind `webrtc-websys` feature flag. - See [PR XXXX](https://github.com/libp2p/rust-libp2p/pull/XXXX) + See [PR 5819](https://github.com/libp2p/rust-libp2p/pull/5819) ## 0.55.0 From 690573b2f8cee2eccfc733d2dd71e3000a0f7625 Mon Sep 17 00:00:00 2001 From: Darius Clark Date: Fri, 17 Jan 2025 06:55:02 -0600 Subject: [PATCH 5/5] Update libp2p/CHANGELOG.md --- libp2p/CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libp2p/CHANGELOG.md b/libp2p/CHANGELOG.md index fdc2e541159..dcf1ad7254d 100644 --- a/libp2p/CHANGELOG.md +++ b/libp2p/CHANGELOG.md @@ -1,6 +1,6 @@ ## 0.55.1 - Introduce `libp2p-webrtc-websys` behind `webrtc-websys` feature flag. - See [PR 5819](https://github.com/libp2p/rust-libp2p/pull/5819) + See [PR 5819](https://github.com/libp2p/rust-libp2p/pull/5819). ## 0.55.0