From 1c579e5caac9f46de53f051baebcbba696b74703 Mon Sep 17 00:00:00 2001 From: vpochapuis Date: Sat, 2 Dec 2023 00:43:34 +0800 Subject: [PATCH 1/3] fix(gloo-net): remove bug-abling EventSource Clone implementation --- crates/net/src/eventsource/futures.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/crates/net/src/eventsource/futures.rs b/crates/net/src/eventsource/futures.rs index daedc576..1d92d692 100644 --- a/crates/net/src/eventsource/futures.rs +++ b/crates/net/src/eventsource/futures.rs @@ -50,7 +50,6 @@ use web_sys::MessageEvent; /// Wrapper around browser's EventSource API. Dropping /// this will close the underlying event source. -#[derive(Clone)] pub struct EventSource { es: web_sys::EventSource, } From 2191ec3840d8d82bc0792122e2b988f99bd89015 Mon Sep 17 00:00:00 2001 From: vpochapuis Date: Sat, 2 Dec 2023 10:33:05 +0800 Subject: [PATCH 2/3] versioning(net): increase version to 0.6.0 --- CHANGELOG.md | 6 ++++++ crates/net/Cargo.toml | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2e6d1f51..b34cd850 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -151,6 +151,12 @@ ## `net` +### Version "0.6.0" + +- Remove `Clone` implementation for `EventSource`. + Due to bug triggering unwanted behavior upon clone, when dropped instances would disconnect all others. + See Discussion (#409) + ### Version "0.5.0" - Implement `futures_io::AsyncWrite` and `futures_io::AsyncRead` on `WebSocket`. diff --git a/crates/net/Cargo.toml b/crates/net/Cargo.toml index 5c9ae3ec..67bce43c 100644 --- a/crates/net/Cargo.toml +++ b/crates/net/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "gloo-net" -version = "0.4.0" +version = "0.6.0" authors = [ "Rust and WebAssembly Working Group", "Muhammad Hamza ", From 3091475e54cc11fa223f61f747255775c8831e6e Mon Sep 17 00:00:00 2001 From: vpochapuis Date: Sat, 2 Dec 2023 10:36:47 +0800 Subject: [PATCH 3/3] dependency(gloo): increase version of dependent crate to the latest version --- Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index c002e966..2b56f3d8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,7 +23,7 @@ gloo-console = { version = "0.3", path = "crates/console", optional = true } gloo-utils = { version = "0.2", path = "crates/utils", optional = true } gloo-history = { version = "0.2", path = "crates/history", optional = true } gloo-worker = { version = "0.4", path = "crates/worker", optional = true } -gloo-net = { version = "0.4", path = "crates/net", optional = true } +gloo-net = { version = "0.6", path = "crates/net", optional = true } [features] default = [