From 71244ab09e8fc14fb913c6edd4fbdfb85d3131fc Mon Sep 17 00:00:00 2001 From: Fabio Valentini Date: Mon, 7 Oct 2024 23:00:09 +0200 Subject: [PATCH] Update to version 0.3.31; Fixes RHBZ#2316600 --- .gitignore | 1 + futures-fix-metadata.diff | 29 +++++++++++++++++++---------- rust-futures.spec | 12 ++++++------ rust2rpm.toml | 26 ++++++++++++++++++++++++++ sources | 2 +- 5 files changed, 53 insertions(+), 17 deletions(-) diff --git a/.gitignore b/.gitignore index 821c20c..62f8bf3 100644 --- a/.gitignore +++ b/.gitignore @@ -29,3 +29,4 @@ /futures-0.3.27.crate /futures-0.3.28.crate /futures-0.3.30.crate +/futures-0.3.31.crate diff --git a/futures-fix-metadata.diff b/futures-fix-metadata.diff index 01e2f42..f1c5da0 100644 --- a/futures-fix-metadata.diff +++ b/futures-fix-metadata.diff @@ -1,17 +1,26 @@ ---- futures-0.3.30/Cargo.toml 1970-01-01T00:00:01+00:00 -+++ futures-0.3.30/Cargo.toml 2024-09-01T00:15:31.426758+00:00 -@@ -80,6 +80,9 @@ +--- futures-0.3.31/Cargo.toml 1970-01-01T00:00:01+00:00 ++++ futures-0.3.31/Cargo.toml 2024-10-07T20:39:19.834381+00:00 +@@ -72,10 +72,6 @@ + path = "tests/bilock.rs" + + [[test]] +-name = "compat" +-path = "tests/compat.rs" +- +-[[test]] + name = "eager_drop" + path = "tests/eager_drop.rs" + +@@ -317,14 +313,14 @@ [dev-dependencies.assert_matches] version = "1.3.0" +[dev-dependencies.futures-test] -+version = "=0.3.30" ++version = "=0.3.31" + [dev-dependencies.pin-project] version = "1.0.11" -@@ -88,9 +91,6 @@ - [dev-dependencies.static_assertions] version = "1" - @@ -20,14 +29,14 @@ [features] alloc = [ -@@ -119,10 +119,6 @@ +@@ -352,10 +348,6 @@ + executor = [ "std", "futures-executor/std", - ] +-] -io-compat = [ - "compat", - "futures-util/io-compat", --] + ] std = [ "alloc", - "futures-core/std", diff --git a/rust-futures.spec b/rust-futures.spec index 34fe113..c13aa74 100644 --- a/rust-futures.spec +++ b/rust-futures.spec @@ -5,7 +5,7 @@ %global crate futures Name: rust-futures -Version: 0.3.30 +Version: 0.3.31 Release: %autorelease Summary: Implementation of futures and streams @@ -16,7 +16,7 @@ Source: %{crates_source} # * add missing futures-test dev-dependency # * drop unused compat support for tokio 0.1 Patch: futures-fix-metadata.diff -Patch: 0001-Fix-compiling-tests-with-io-compat-feature-removed.patch +Patch10: 0001-Fix-compiling-tests-with-io-compat-feature-removed.patch BuildRequires: cargo-rpm-macros >= 24 @@ -202,11 +202,11 @@ rm tests/compat.rs %if %{with check} %check -# * always skip a test that is officially "flaky" -# * skip a possibly flaky test: +# * always skip a test that is officially "flaky" (stream_select) +# * skip a possibly flaky test (many_threads): # https://github.com/rust-lang/futures-rs/issues/2539 -# * skip a test which fails depending on Rust version: -# sizes of some structs and enums changed between Rust 1.62 and 1.63 +# * skip a test which fails depending on Rust version (join_size): sizes of some +# structs and enums changed between Rust 1.62 and 1.63 %cargo_test -a -- -- --skip stream_select --skip many_threads --skip join_size %endif diff --git a/rust2rpm.toml b/rust2rpm.toml index 73ad5b0..00dc928 100644 --- a/rust2rpm.toml +++ b/rust2rpm.toml @@ -1,6 +1,32 @@ [package] summary = "Implementation of futures and streams" +cargo-toml-patch-comments = [ + "add missing futures-test dev-dependency", + "drop unused compat support for tokio 0.1", +] + +[[package.extra-patches]] +number = 10 +file = "0001-Fix-compiling-tests-with-io-compat-feature-removed.patch" [features] enable-all = true +[scripts] +prep.post = [ + "# drop single test that depends on tokio 0.1", + "rm tests/compat.rs", +] + +[tests] +skip = [ + "stream_select", + "many_threads", + "join_size", +] +comments = [ + "always skip a test that is officially \"flaky\" (stream_select)", + "skip a possibly flaky test (many_threads): https://github.com/rust-lang/futures-rs/issues/2539", + "skip a test which fails depending on Rust version (join_size): sizes of some structs and enums changed between Rust 1.62 and 1.63", +] + diff --git a/sources b/sources index d73c9ec..7ee12f4 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (futures-0.3.30.crate) = 98fc67bf1047609c8bb0763c00ab9cb39b6a6d0cb7d993bce4966ddc2492a6578b789e98095981b207ddd73ac4b1dfcd5224b352a0e970eed347537c6fbea43e +SHA512 (futures-0.3.31.crate) = a08d23cdac9e162d0e6ae72bd792201ff4e13d7ade6b498cc597149b3df2062b06814804c0750d941d8b5be5d2ab4cfebbe2d08a98d875d2092bf25e6e71a51d