Update to libp2p-0.36 (#8420)

* Update to libp2p-0.36

* Some more Cargo.lock updates.
This commit is contained in:
Roman Borschel
2021-03-24 19:29:35 +01:00
committed by GitHub
parent 9a72134188
commit e1570b9ab4
15 changed files with 246 additions and 75 deletions
+1 -1
View File
@@ -18,7 +18,7 @@ targets = ["x86_64-unknown-linux-gnu"]
parking_lot = "0.11.1"
futures = "0.3.9"
wasm-timer = "0.2.5"
libp2p = { version = "0.35.1", default-features = false, features = ["dns", "tcp-async-io", "wasm-ext", "websocket"] }
libp2p = { version = "0.36.0", default-features = false, features = ["dns-async-std", "tcp-async-io", "wasm-ext", "websocket"] }
log = "0.4.8"
pin-project = "1.0.4"
rand = "0.7.2"
+2 -1
View File
@@ -17,6 +17,7 @@
// along with this program. If not, see <https://www.gnu.org/licenses/>.
use futures::{
executor::block_on,
prelude::*,
ready,
task::{Context, Poll},
@@ -47,7 +48,7 @@ pub(crate) fn initialize_transport(
// an external transport on desktop and the fallback is used all the time.
#[cfg(not(target_os = "unknown"))]
let transport = transport.or_transport({
let inner = libp2p::dns::DnsConfig::new(libp2p::tcp::TcpConfig::new())?;
let inner = block_on(libp2p::dns::DnsConfig::system(libp2p::tcp::TcpConfig::new()))?;
libp2p::websocket::framed::WsConfig::new(inner).and_then(|connec, _| {
let connec = connec
.with(|item| {