deps: update jsonrpsee 0.2.0 (#285)

* deps: update jsonrpsee 0.2.0

The motivation is to avoid pinning certain alpha versions and to avoid
breaking users builds without having to some `Cargo.lock` updating.

* cargo fmt

* fix tests

* fix a few clippy lints

* cargo fmt
This commit is contained in:
Niklas Adolfsson
2021-06-08 19:15:12 +02:00
committed by GitHub
parent 490836fa2d
commit 08a3e6574d
7 changed files with 73 additions and 50 deletions
+9 -9
View File
@@ -31,19 +31,19 @@ use core::{
marker::PhantomData,
};
use frame_metadata::RuntimeMetadataPrefixed;
use jsonrpsee_http_client::{
use jsonrpsee_http_client::HttpClient;
use jsonrpsee_types::{
to_json_value,
traits::Client,
traits::{
Client,
SubscriptionClient,
},
DeserializeOwned,
Error as RpcError,
HttpClient,
JsonValue,
};
use jsonrpsee_ws_client::{
traits::SubscriptionClient,
Subscription,
WsClient,
};
use jsonrpsee_ws_client::WsClient;
use serde::{
Deserialize,
Serialize,
@@ -541,7 +541,7 @@ impl<T: Runtime> Rpc<T> {
}?;
let mut xt_sub = self.watch_extrinsic(extrinsic).await?;
while let Some(status) = xt_sub.next().await {
while let Ok(Some(status)) = xt_sub.next().await {
log::info!("received status {:?}", status);
match status {
// ignore in progress extrinsic for now
@@ -604,7 +604,7 @@ impl<T: Runtime> Rpc<T> {
ext_hash,
))
})?;
let mut sub = EventSubscription::new(events_sub, &decoder);
let mut sub = EventSubscription::new(events_sub, decoder);
sub.filter_extrinsic(block_hash, ext_index);
let mut events = vec![];
while let Some(event) = sub.next().await {