Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated directory_client reqwest to 0.10 #226

Merged
merged 2 commits into from
May 12, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
187 changes: 179 additions & 8 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion clients/desktop/src/client/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ use gateway_client::{GatewayClient, SphinxPacketReceiver, SphinxPacketSender};
use gateway_requests::auth_token::AuthToken;
use log::*;
use nymsphinx::chunking::split_and_prepare_payloads;
use nymsphinx::{Destination, DestinationAddressBytes};
use nymsphinx::DestinationAddressBytes;
use received_buffer::{ReceivedBufferMessage, ReconstructedMessagesReceiver};

use tokio::runtime::Runtime;
Expand Down
3 changes: 2 additions & 1 deletion clients/desktop/src/client/topology_control.rs
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,8 @@ impl<T: 'static + NymTopology> TopologyRefresher<T> {
}

async fn get_current_compatible_topology(&self) -> T {
let full_topology = T::new(self.directory_server.clone());
// note: this call makes it neccessary that `T::new()`does *not* have 'static lifetime
let full_topology = T::new(self.directory_server.clone()).await;
// just filter by version and assume the validators will remove all bad behaving
// nodes with the staking
full_topology.filter_system_version(built_info::PKG_VERSION)
Expand Down
2 changes: 1 addition & 1 deletion clients/desktop/src/commands/init.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ async fn choose_gateway(
our_address: DestinationAddressBytes,
) -> (String, AuthToken) {
// TODO: once we change to graph topology this here will need to be updated!
let topology = Topology::new(directory_server.clone());
let topology = Topology::new(directory_server.clone()).await;
let version_filtered_topology = topology.filter_system_version(built_info::PKG_VERSION);
// don't care about health of the networks as mixes can go up and down any time,
// but DO care about gateways
Expand Down
4 changes: 3 additions & 1 deletion common/client-libs/directory-client/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@ edition = "2018"

[dependencies]
log = "0.4"
futures = "0.3"
pretty_env_logger = "0.3"
reqwest = "0.9.22"
reqwest = { version = "0.10", features = ["json"] }
serde = { version = "1.0.104", features = ["derive"] }

## internal
topology = {path = "../../topology"}

[dev-dependencies]
mockito = "0.23.0"
tokio = { version = "0.2", features = ["macros"] }
Loading