Skip to content

Commit 1e011ea

Browse files
committed
Actually return the GenServer::init result.
1 parent 08d83b4 commit 1e011ea

File tree

6 files changed

+11
-7
lines changed

6 files changed

+11
-7
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@
66

77
### Fixed
88

9+
# 0.1.38
10+
11+
### Fixed
12+
- Return if process exited from `GenServer::init`.
13+
914
# 0.1.37
1015

1116
### Fixed

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ tracing = { version = "0.1", default-features = false, features = ["std"] }
3333
tracing-subscriber = "0.3"
3434
dashmap = "6.0.1"
3535

36-
hydra-macros = { version = "0.1.37", path = "./hydra-macros" }
37-
hydra = { version = "0.1.37", path = "./hydra", default-features = false }
36+
hydra-macros = { version = "0.1.38", path = "./hydra-macros" }
37+
hydra = { version = "0.1.38", path = "./hydra", default-features = false }
3838

3939
[profile.release]
4040
lto = "fat"

hydra-macros/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "hydra-macros"
3-
version = "0.1.37"
3+
version = "0.1.38"
44
edition = "2021"
55
license.workspace = true
66
repository.workspace = true

hydra-websockets/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "hydra-websockets"
3-
version = "0.1.37"
3+
version = "0.1.38"
44
edition = "2021"
55
readme = "./README.md"
66
license.workspace = true

hydra/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "hydra"
3-
version = "0.1.37"
3+
version = "0.1.38"
44
edition = "2021"
55
readme.workspace = true
66
license.workspace = true

hydra/src/gen_server.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,6 @@ pub trait GenServer: Sized + Send + 'static {
130130
/// Starts a [GenServer] process linked to the current process.
131131
fn start_link(
132132
self,
133-
134133
options: GenServerOptions,
135134
) -> impl Future<Output = Result<Pid, ExitReason>> + Send {
136135
async { start_gen_server(self, options, true).await }
@@ -460,6 +459,6 @@ async fn start_gen_server<T: GenServer>(
460459
};
461460

462461
rx.await
462+
.map_err(|_| ExitReason::from("unknown"))?
463463
.map(|_| pid)
464-
.map_err(|_| ExitReason::from("unknown"))
465464
}

0 commit comments

Comments
 (0)