Depend on futures-util instead of futures

This commit is contained in:
TechnoPorg committed 2026-02-11 22:44:01 +01:00
1 parent f342e33f16
commit a75defa5a6
79 files changed
+447 -380

No files matched your search

+2 -2
View File
@@ -31,7 +31,7 @@
//! ```
use dagx::{task, DagRunner};
use futures::FutureExt;
// Step 1: Define a source task (no dependencies)
//
@@ -106,7 +106,7 @@ async fn main() {
// 1. Tasks with no dependencies run first (x and y in parallel)
// 2. Once x and y complete, sum runs (it depends on both)
println!("Running DAG...\n");
dag.run(|fut| tokio::spawn(fut).map(Result::unwrap))
dag.run(|fut| async move { tokio::spawn(fut).await.unwrap() })
.await
.unwrap();