Compare commits
3 Commits
Author | SHA1 | Date | |
---|---|---|---|
3c3f638004 | |||
ea5287152c
|
|||
14371cdfd7 |
@@ -6,6 +6,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
## [Unreleased]
|
||||
|
||||
## [0.7.0] - 2024-11-24
|
||||
|
||||
### Added
|
||||
- actually bubble up errors
|
||||
|
||||
### Fixed
|
||||
- *(deps)* update rust crate thiserror to v2 (#9)
|
||||
|
||||
## [0.6.0] - 2024-11-23
|
||||
|
||||
### Added
|
||||
|
10
Cargo.lock
generated
10
Cargo.lock
generated
@@ -266,7 +266,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "notmad"
|
||||
version = "0.5.0"
|
||||
version = "0.6.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"async-trait",
|
||||
@@ -525,18 +525,18 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "thiserror"
|
||||
version = "1.0.69"
|
||||
version = "2.0.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52"
|
||||
checksum = "c006c85c7651b3cf2ada4584faa36773bd07bac24acfb39f3c431b36d7e667aa"
|
||||
dependencies = [
|
||||
"thiserror-impl",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "thiserror-impl"
|
||||
version = "1.0.69"
|
||||
version = "2.0.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1"
|
||||
checksum = "f077553d607adc1caf65430528a576c757a71ed73944b66ebb58ef2bbd243568"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
|
@@ -3,7 +3,7 @@ members = ["crates/*"]
|
||||
resolver = "2"
|
||||
|
||||
[workspace.package]
|
||||
version = "0.6.0"
|
||||
version = "0.7.0"
|
||||
|
||||
[workspace.dependencies]
|
||||
mad = { path = "crates/mad" }
|
||||
|
@@ -13,7 +13,7 @@ async-trait = "0.1.81"
|
||||
futures = "0.3.30"
|
||||
futures-util = "0.3.30"
|
||||
rand = "0.8.5"
|
||||
thiserror = "1.0.63"
|
||||
thiserror = "2.0.0"
|
||||
tokio.workspace = true
|
||||
tokio-util = "0.7.11"
|
||||
tracing.workspace = true
|
||||
|
@@ -197,6 +197,7 @@ impl Mad {
|
||||
futures.push(channel.recv());
|
||||
}
|
||||
|
||||
let mut errors = Vec::new();
|
||||
while let Some(Some(msg)) = futures.next().await {
|
||||
match msg.res {
|
||||
Err(e) => {
|
||||
@@ -205,6 +206,7 @@ impl Mad {
|
||||
component = msg.name,
|
||||
"component ran to completion with error"
|
||||
);
|
||||
errors.push(e);
|
||||
}
|
||||
Ok(_) => {
|
||||
tracing::debug!(component = msg.name, "component ran to completion");
|
||||
@@ -215,6 +217,9 @@ impl Mad {
|
||||
}
|
||||
|
||||
tracing::debug!("ran components");
|
||||
if !errors.is_empty() {
|
||||
return Err(MadError::AggregateError(AggregateError { errors }));
|
||||
}
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
Reference in New Issue
Block a user