Skip to content

Commit

Permalink
Updated futures-rs, tokio, tower and rust
Browse files Browse the repository at this point in the history
- rust nightly-2019-10-04 (Requires new docker image build)
- futures alpha.19
- tokio alpha.6
- tower alpha2

Came across this panic in the rust compiler in a PR to follow:
rust-lang/rust#64385
  • Loading branch information
sdbondi committed Oct 11, 2019
1 parent 254b2d0 commit 263d7b4
Show file tree
Hide file tree
Showing 13 changed files with 31 additions and 37 deletions.
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: 2

defaults:
rust_image: &rust_image quay.io/tarilabs/rust_tari-build-with-deps:nightly-2019-09-13
rust_image: &rust_image quay.io/tarilabs/rust_tari-build-with-deps:nightly-2019-10-04

jobs:
test-docs:
Expand Down Expand Up @@ -70,7 +70,7 @@ jobs:
- run:
name: Tari source code
command: |
TOOLCHAIN_VERSION=nightly-2019-09-13
TOOLCHAIN_VERSION=nightly-2019-10-04
rustup component add --toolchain $TOOLCHAIN_VERSION rustfmt
cargo fmt --all -- --check
cargo test --all
Expand Down
4 changes: 2 additions & 2 deletions applications/console_text_messenger/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ clap = "2.33.0"
config = { version = "0.9.3" }
crossbeam-channel = "0.3.8"
ctrlc = "3.1.3"
futures = { version = "=0.3.0-alpha.18", package = "futures-preview", features =["compat", "std"]}
futures = { version = "=0.3.0-alpha.19", package = "futures-preview", features =["compat", "std"]}
log = { version = "0.4.0", features = ["std"] }
log4rs = {version ="0.8.3",features = ["console_appender", "file_appender", "file", "yaml_format"]}
pnet = "0.22.0"
serde = "1.0.90"
serde_derive = "1.0.90"
simple_logger = "1.2.0"
tokio = "0.2.0-alpha.4"
tokio = "0.2.0-alpha.6"
6 changes: 3 additions & 3 deletions base_layer/core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ blake2 = "^0.8.0"
bigint = "^4.4.1"
ttl_cache = "0.5.1"
croaring = "^0.4.0"
tokio = { version="^0.2.0-alpha.4" }
tokio-executor = { version ="^0.2.0-alpha.4", features = ["threadpool"] }
futures-preview = {version = "0.3.0-alpha.18", features = ["nightly", "async-await"] }
tokio = { version="^0.2.0-alpha.6" }
tokio-executor = { version ="^0.2.0-alpha.6", features = ["threadpool"] }
futures-preview = {version = "0.3.0-alpha.19", features = ["async-await"] }
lmdb-zero = "0.4.4"

[dev-dependencies]
Expand Down
8 changes: 4 additions & 4 deletions base_layer/p2p/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,19 @@ tari_broadcast_channel = { version="^0.0", path = "../../infrastructure/broadca
chrono = { version = "0.4.6", features = ["serde"]}
crossbeam-channel = "0.3.8"
derive-error = "0.0.4"
futures = { version = "=0.3.0-alpha.18", package = "futures-preview"}
futures = { version = "=0.3.0-alpha.19", package = "futures-preview"}
lmdb-zero = "0.4.4"
log = "0.4.6"
rand = "0.6.5"
rmp-serde = "0.13.7"
serde = "1.0.90"
serde_derive = "1.0.90"
threadpool = "1.7.1"
tokio = "0.2.0-alpha.4"
tower-service = { version="0.3.0-alpha.1" }
tokio = "0.2.0-alpha.6"
tower-service = { version="0.3.0-alpha.2" }
tracing = "0.1.5"
ttl_cache = "0.5.1"
tower = "0.3.0-alpha.1a"
tower = "0.3.0-alpha.2"

[dev-dependencies]
tari_test_utils = { version = "^0.0", path="../../infrastructure/test_utils" }
Expand Down
6 changes: 3 additions & 3 deletions base_layer/service_framework/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ edition = "2018"

[dependencies]
derive-error = "0.0.4"
futures = { version = "=0.3.0-alpha.18", package = "futures-preview", features=["async-await", "nightly"]}
tower-service = { version="0.3.0-alpha.1" }
tokio = "0.2.0-alpha.4"
futures = { version = "=0.3.0-alpha.19", package = "futures-preview", features=["async-await"]}
tower-service = { version="0.3.0-alpha.2" }
tokio = "0.2.0-alpha.6"

[dev-dependencies]
tari_test_utils = { version = "^0.0", path="../../infrastructure/test_utils" }
Expand Down
6 changes: 3 additions & 3 deletions base_layer/wallet/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@ lmdb-zero = "0.4.4"
#diesel_migrations = "1.4"
#diesel = {version="1.4", features = ["sqlite", "serde_json", "chrono", "r2d2"]}
rand = "0.5.5"
futures = { version = "=0.3.0-alpha.18", package = "futures-preview", features =["compat", "std"]}
futures = { version = "=0.3.0-alpha.19", package = "futures-preview", features =["compat", "std"]}
tokio = "0.2.0-alpha.4"
tower = "0.3.0-alpha.1a"
tokio-executor = { version ="^0.2.0-alpha.4", features = ["threadpool"] }
tower = "0.3.0-alpha.2"
tokio-executor = { version ="^0.2.0-alpha.6", features = ["threadpool"] }

[dev-dependencies]
env_logger = "0.6.2"
Expand Down
4 changes: 2 additions & 2 deletions comms/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@ chrono = { version = "0.4.6", features = ["serde"] }
clear_on_drop = "0.2.3"
derive-error = "0.0.4"
digest = "0.8.0"
futures = { version = "=0.3.0-alpha.18", package = "futures-preview", features =["compat", "async-await", "nightly"]}
futures = { version = "=0.3.0-alpha.19", package = "futures-preview", features =[ "async-await"]}
lazy_static = "1.3.0"
lmdb-zero = "0.4.4"
log = { version = "0.4.0", features = ["std"] }
rand = "0.5.5"
serde = "1.0.90"
serde_derive = "1.0.90"
time = "0.1.42"
tokio = "0.2.0-alpha.4"
tokio = "0.2.0-alpha.6"
ttl_cache = "0.5.1"
zmq = "0.9.1"
serde_repr = "0.1.5"
Expand Down
8 changes: 4 additions & 4 deletions comms/dht/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@ bitflags = "1.2.0"
chrono = "0.4.9"
derive-error = "0.0.4"
digest = "0.8.1"
futures= {version= "0.3.0-alpha.18", package="futures-preview"}
futures= {version= "0.3.0-alpha.19", package="futures-preview"}
log = "0.4.8"
rand = "0.5.5"
serde = "1.0.90"
serde_derive = "1.0.90"
serde_repr = "0.1.5"
tokio = "0.2.0-alpha.4"
tokio-executor = "0.2.0-alpha.4"
tower= "0.3.0-alpha.1a"
tokio = "0.2.0-alpha.6"
tokio-executor = "0.2.0-alpha.6"
tower= "0.3.0-alpha.2"
ttl_cache = "0.5.1"

[dev-dependencies]
Expand Down
6 changes: 3 additions & 3 deletions comms/middleware/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@ tari_pubsub = { version="^0.0", path="../../infrastructure/pubsub"}
tari_utilities = { version = "^0.0", path = "../../infrastructure/tari_util"}

derive-error = "0.0.4"
futures= {version= "0.3.0-alpha.18", package="futures-preview"}
futures= {version= "0.3.0-alpha.19", package="futures-preview"}
log = "0.4.8"
serde = "1.0.90"
serde_derive = "1.0.90"
tokio = "0.2.0-alpha.4"
tower= "0.3.0-alpha.1a"
tokio = "0.2.0-alpha.6"
tower= "0.3.0-alpha.2"
rand = "0.5.5"

[dev-dependencies]
Expand Down
5 changes: 2 additions & 3 deletions infrastructure/broadcast_channel/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,12 @@ edition = "2018"

[dependencies]
arc-swap = "0.4.2"
futures = { version = "=0.3.0-alpha.18", package = "futures-preview" }
futures = { version = "=0.3.0-alpha.19", package = "futures-preview" }
crossbeam-channel = "0.3.9"

[dev-dependencies]
criterion = "0.3.0"
tokio = "0.2.0-alpha.4"
futures = { version = "=0.3.0-alpha.18", package = "futures-preview"}
tokio = "0.2.0-alpha.6"

[[example]]
name = "raw-simple"
Expand Down
2 changes: 1 addition & 1 deletion infrastructure/pubsub/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ edition = "2018"

[dependencies]
tari_broadcast_channel = { version="^0.0", path = "../broadcast_channel" }
futures = { version = "=0.3.0-alpha.18", package = "futures-preview", features=["async-await", "nightly", "compat"] }
futures = { version = "=0.3.0-alpha.19", package = "futures-preview", features=["async-await"] }
7 changes: 1 addition & 6 deletions infrastructure/pubsub/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
// USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
use futures::{compat::Compat, future, prelude::*, stream::Fuse};
use futures::{future, prelude::*, stream::Fuse};
use std::fmt::Debug;
use tari_broadcast_channel::{bounded, Publisher, Subscriber};

Expand Down Expand Up @@ -76,11 +76,6 @@ where
})
}

/// Provide a Compat wrapped version of the subscription stream for things that want to consume old-style streams
pub fn get_subscription_compat(&self, topic: T) -> Compat<impl Stream<Item = Result<M, ()>>> {
self.get_subscription(topic).map(|i| Ok(i)).compat()
}

/// Provide a fused version of the subscription stream so that domain modules don't need to know about fuse()
pub fn get_subscription_fused(&self, topic: T) -> Fuse<impl Stream<Item = M>> {
self.get_subscription(topic).fuse()
Expand Down
2 changes: 1 addition & 1 deletion rust-toolchain
Original file line number Diff line number Diff line change
@@ -1 +1 @@
nightly-2019-09-13
nightly-2019-10-04

0 comments on commit 263d7b4

Please sign in to comment.