mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-27 13:57:58 +00:00
Upgrade from futures-preview to futures 0.3.1, and remove futures 0.1 where currently possible (#4083)
* Migrate node and node-template * Migrate srml * Simple changes * Add async-std for interval * Fix test-runtime warning * Small changes * move futures01 in core/rpc to dev-deps * Change wasm CI builds * Switch to async-std 1.0.1 * Remove async-std dep of network * Add modified lockfile * Fix node cli browser build * Remove authority-discovery async-std dep * Add Send + Sync to interval dyn stream
This commit is contained in:
@@ -19,7 +19,7 @@
|
||||
#[cfg(test)]
|
||||
mod tests;
|
||||
|
||||
use futures03::{channel::{mpsc, oneshot}, compat::Compat};
|
||||
use futures::{channel::{mpsc, oneshot}, compat::Compat};
|
||||
use api::Receiver;
|
||||
use sr_primitives::traits::{self, Header as HeaderT};
|
||||
use self::error::Result;
|
||||
|
||||
@@ -20,7 +20,7 @@ use network::{self, PeerId};
|
||||
use network::config::Roles;
|
||||
use test_client::runtime::Block;
|
||||
use assert_matches::assert_matches;
|
||||
use futures03::{prelude::*, channel::mpsc};
|
||||
use futures::{prelude::*, channel::mpsc};
|
||||
use std::thread;
|
||||
|
||||
struct Status {
|
||||
@@ -46,7 +46,7 @@ fn api<T: Into<Option<Status>>>(sync: T) -> System<Block> {
|
||||
let should_have_peers = !status.is_dev;
|
||||
let (tx, rx) = mpsc::unbounded();
|
||||
thread::spawn(move || {
|
||||
futures03::executor::block_on(rx.for_each(move |request| {
|
||||
futures::executor::block_on(rx.for_each(move |request| {
|
||||
match request {
|
||||
Request::Health(sender) => {
|
||||
let _ = sender.send(Health {
|
||||
@@ -231,4 +231,4 @@ fn system_node_roles() {
|
||||
wait_receiver(api(None).system_node_roles()),
|
||||
vec![NodeRole::Authority]
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user