alexcrichton / tokio-curl

Asynchronous HTTP client built on libcurl
Apache License 2.0
110 stars 15 forks source link

Dependency `futures` is out-of-date #24

Open DeadBushSanpai opened 9 months ago

DeadBushSanpai commented 9 months ago

The examples/two.rs will fail if using latest futures(version = 0.3.30). It will pass using version show in Cargo.toml (version = 0.1.15). The error log(already remove some line from examples/two.rs):

   Compiling playground v0.1.0 (/home/dead_bush_sanpai/workspace/code/playground)
warning: unused import: `futures::Future`
  --> src/main.rs:11:5
   |
11 | use futures::Future;
   |     ^^^^^^^^^^^^^^^
   |
   = note: `#[warn(unused_imports)]` on by default

error[E0599]: no method named `join` found for struct `Perform` in the current scope
   --> src/main.rs:33:39
    |
33  |     let requests = session.perform(a).join(session.perform(b));
    |                                       ^^^^ method not found in `Perform`
    |
   ::: /home/dead_bush_sanpai/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/futures-0.1.31/src/future/mod.rs:716:8
    |
716 |     fn join<B>(self, other: B) -> Join<Self, B::Future>
    |        ---- the method is available for `Perform` here
    |
    = help: items from traits can only be used if the trait is in scope
help: the following trait is implemented but not in scope; perhaps add a `use` for it:
    |
6   + use futures::future::Future;
    |

For more information about this error, try `rustc --explain E0599`.
warning: `playground` (bin "playground") generated 1 warning
error: could not compile `playground` (bin "playground") due to previous error; 1 warning emitted