From 4c9860e7e46266abc9deb2390e233c5f2069a9cc Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Tue, 25 Jan 2022 17:08:47 +0100 Subject: [PATCH 01/34] Bump version to 0.3.9 --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index d00847ec..e8100ecf 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -25,7 +25,7 @@ dependencies = [ [[package]] name = "async-compression" -version = "0.3.8" +version = "0.3.9" dependencies = [ "brotli", "bytes 0.5.6", diff --git a/Cargo.toml b/Cargo.toml index 33cee879..18f0594a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "async-compression" -version = "0.3.8" +version = "0.3.9" authors = ["Wim Looman ", "Allen Bui "] edition = "2018" license = "MIT OR Apache-2.0" From 9af5b00cf0cc16f93b64a10a60d62d1e39072575 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Tue, 25 Jan 2022 17:11:59 +0100 Subject: [PATCH 02/34] Update all locked dependencies --- Cargo.lock | 330 ++++++++++++++++++++++------------------------------- 1 file changed, 138 insertions(+), 192 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index e8100ecf..3499016a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -10,9 +10,9 @@ checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" [[package]] name = "alloc-no-stdlib" -version = "2.0.1" +version = "2.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5192ec435945d87bc2f70992b4d818154b5feede43c09fb7592146374eac90a6" +checksum = "35ef4730490ad1c4eae5c4325b2a95f521d023e5c885853ff7aca0a6a1631db3" [[package]] name = "alloc-stdlib" @@ -30,7 +30,7 @@ dependencies = [ "brotli", "bytes 0.5.6", "bytes 0.6.0", - "bytes 1.0.1", + "bytes 1.1.0", "bzip2", "flate2", "futures", @@ -40,17 +40,17 @@ dependencies = [ "futures_codec", "memchr", "ntest", - "pin-project-lite 0.2.6", + "pin-project-lite 0.2.8", "proptest", "proptest-derive", "rand 0.7.3", "tokio 0.2.25", "tokio 0.3.7", - "tokio 1.5.0", + "tokio 1.15.0", "tokio-util 0.3.1", "tokio-util 0.4.0", "tokio-util 0.5.1", - "tokio-util 0.6.6", + "tokio-util 0.6.9", "xz2", "zstd", "zstd-safe", @@ -85,15 +85,15 @@ checksum = "349f9b6a179ed607305526ca489b34ad0a41aed5f7980fa90eb03160b69598fb" [[package]] name = "bitflags" -version = "1.2.1" +version = "1.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf1de2fe8c75bc145a2f577add951f8134889b4795d47466a54a5c846d691693" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "brotli" -version = "3.3.0" +version = "3.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f29919120f08613aadcd4383764e00526fc9f18b6c0895814faeed0dd78613e" +checksum = "f838e47a451d5a8fa552371f80024dd6ace9b7acdf25c4c3d0f9bc6816fb1c39" dependencies = [ "alloc-no-stdlib", "alloc-stdlib", @@ -102,9 +102,9 @@ dependencies = [ [[package]] name = "brotli-decompressor" -version = "2.3.1" +version = "2.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1052e1c3b8d4d80eb84a8b94f0a1498797b5fb96314c001156a1c761940ef4ec" +checksum = "59ad2d4653bf5ca36ae797b1f4bb4dbddb60ce49ca4aed8a2ce4829f60425b80" dependencies = [ "alloc-no-stdlib", "alloc-stdlib", @@ -130,15 +130,15 @@ checksum = "e0dcbc35f504eb6fc275a6d20e4ebcda18cf50d40ba6fabff8c711fa16cb3b16" [[package]] name = "bytes" -version = "1.0.1" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b700ce4376041dcd0a327fd0097c41095743c4c8af8887265942faf1100bd040" +checksum = "c4872d67bab6358e59559027aa3b9157c53d9358c51423c17554809a8858e0f8" [[package]] name = "bzip2" -version = "0.4.2" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abf8012c8a15d5df745fcf258d93e6149dcf102882c8d8702d9cff778eab43a8" +checksum = "6afcd980b5f3a45017c57e57a2fcccbb351cc43a356ce117ef760ef8052b89b0" dependencies = [ "bzip2-sys", "libc", @@ -146,9 +146,9 @@ dependencies = [ [[package]] name = "bzip2-sys" -version = "0.1.10+1.0.8" +version = "0.1.11+1.0.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17fa3d1ac1ca21c5c4e36a97f3c3eb25084576f6fc47bf0139c1123434216c6c" +checksum = "736a955f3fa7875102d57c82b8cac37ec45224a07fd32d58f9f7a186b6cd4cdc" dependencies = [ "cc", "libc", @@ -157,9 +157,9 @@ dependencies = [ [[package]] name = "cc" -version = "1.0.67" +version = "1.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3c69b077ad434294d3ce9f1f6143a2a4b89a8a2d54ef813d85003a4fd1137fd" +checksum = "22a9137b95ea06864e018375b72adfb7db6e6f68cfc8df5a04d00288050485ee" dependencies = [ "jobserver", ] @@ -181,18 +181,27 @@ dependencies = [ [[package]] name = "crc32fast" -version = "1.2.1" +version = "1.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81156fece84ab6a9f2afdb109ce3ae577e42b1228441eded99bd77f627953b1a" +checksum = "a2209c310e29876f7f0b2721e7e26b84aff178aa3da5d091f9bfbf47669e60e3" dependencies = [ "cfg-if", ] +[[package]] +name = "fastrand" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3fcf0cee53519c866c09b5de1f6c56ff9d647101f81c1964fa632e148896cdf" +dependencies = [ + "instant", +] + [[package]] name = "flate2" -version = "1.0.20" +version = "1.0.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd3aec53de10fe96d7d8c565eb17f2c687bb5518a2ec453b5b1252964526abe0" +checksum = "1e6988e897c1c9c485f43b47a529cef42fde0547f9d8d41a7062518f1d8fc53f" dependencies = [ "cfg-if", "crc32fast", @@ -214,9 +223,9 @@ checksum = "a06f77d526c1a601b7c4cdd98f54b5eaabffc14d5f2f0296febdc7f357c6d3ba" [[package]] name = "futures" -version = "0.3.14" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9d5813545e459ad3ca1bff9915e9ad7f1a47dc6a91b627ce321d5863b7dd253" +checksum = "28560757fe2bb34e79f907794bb6b22ae8b0e5c669b638a1132f2592b19035b4" dependencies = [ "futures-channel", "futures-core", @@ -229,9 +238,9 @@ dependencies = [ [[package]] name = "futures-channel" -version = "0.3.14" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce79c6a52a299137a6013061e0cf0e688fce5d7f1bc60125f520912fdb29ec25" +checksum = "ba3dda0b6588335f360afc675d0564c17a77a2bda81ca178a4b6081bd86c7f0b" dependencies = [ "futures-core", "futures-sink", @@ -239,15 +248,15 @@ dependencies = [ [[package]] name = "futures-core" -version = "0.3.14" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "098cd1c6dda6ca01650f1a37a794245eb73181d0d4d4e955e2f3c37db7af1815" +checksum = "d0c8ff0461b82559810cdccfde3215c3f373807f5e5232b71479bff7bb2583d7" [[package]] name = "futures-executor" -version = "0.3.14" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10f6cb7042eda00f0049b1d2080aa4b93442997ee507eb3828e8bd7577f94c9d" +checksum = "29d6d2ff5bb10fb95c85b8ce46538a2e5f5e7fdc755623a7d4529ab8a4ed9d2a" dependencies = [ "futures-core", "futures-task", @@ -256,55 +265,55 @@ dependencies = [ [[package]] name = "futures-io" -version = "0.3.14" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "365a1a1fb30ea1c03a830fdb2158f5236833ac81fa0ad12fe35b29cddc35cb04" +checksum = "b1f9d34af5a1aac6fb380f735fe510746c38067c5bf16c7fd250280503c971b2" [[package]] name = "futures-macro" -version = "0.3.14" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "668c6733a182cd7deb4f1de7ba3bf2120823835b3bcfbeacf7d2c4a773c1bb8b" +checksum = "6dbd947adfffb0efc70599b3ddcf7b5597bb5fa9e245eb99f62b3a5f7bb8bd3c" dependencies = [ - "proc-macro-hack", - "proc-macro2 1.0.26", - "quote 1.0.9", - "syn 1.0.70", + "proc-macro2 1.0.36", + "quote 1.0.15", + "syn 1.0.86", ] [[package]] name = "futures-sink" -version = "0.3.14" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5629433c555de3d82861a7a4e3794a4c40040390907cfbfd7143a92a426c23" +checksum = "e3055baccb68d74ff6480350f8d6eb8fcfa3aa11bdc1a1ae3afdd0514617d508" [[package]] name = "futures-task" -version = "0.3.14" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba7aa51095076f3ba6d9a1f702f74bd05ec65f555d70d2033d55ba8d69f581bc" +checksum = "6ee7c6485c30167ce4dfb83ac568a849fe53274c831081476ee13e0dce1aad72" [[package]] name = "futures-test" -version = "0.3.14" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e77baeade98824bc928c21b8ad39918b9d8a06745ebdb6e2c93fb7673fb7968d" +checksum = "4e741bc851e1e90ad08901b329389ae77e02d5e9a0ec61955b80834630fbdc2f" dependencies = [ "futures-core", "futures-executor", "futures-io", + "futures-macro", "futures-sink", "futures-task", "futures-util", - "pin-project 1.0.7", + "pin-project 1.0.10", "pin-utils", ] [[package]] name = "futures-util" -version = "0.3.14" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c144ad54d60f23927f0a6b6d816e4271278b64f005ad65e4e35291d2de9c025" +checksum = "d9b5cf40b47a271f77a8b1bec03ca09044d99d2372c0de244e66430761127164" dependencies = [ "futures-channel", "futures-core", @@ -313,10 +322,8 @@ dependencies = [ "futures-sink", "futures-task", "memchr", - "pin-project-lite 0.2.6", + "pin-project-lite 0.2.8", "pin-utils", - "proc-macro-hack", - "proc-macro-nested", "slab", ] @@ -329,7 +336,7 @@ dependencies = [ "bytes 0.5.6", "futures", "memchr", - "pin-project 0.4.28", + "pin-project 0.4.29", ] [[package]] @@ -340,25 +347,23 @@ checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" dependencies = [ "cfg-if", "libc", - "wasi 0.9.0+wasi-snapshot-preview1", + "wasi", ] [[package]] -name = "getrandom" -version = "0.2.2" +name = "instant" +version = "0.1.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9495705279e7140bf035dde1f6e750c162df8b625267cd52cc44e0b156732c8" +checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" dependencies = [ "cfg-if", - "libc", - "wasi 0.10.2+wasi-snapshot-preview1", ] [[package]] name = "jobserver" -version = "0.1.22" +version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "972f5ae5d1cb9c6ae417789196c803205313edde988685da5e3aae0827b9e7fd" +checksum = "af25a77299a7f711a01975c35a6a424eb6862092cc2d6c72c4ed6cbc56dfc1fa" dependencies = [ "libc", ] @@ -371,9 +376,9 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" [[package]] name = "libc" -version = "0.2.93" +version = "0.2.114" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9385f66bf6105b241aa65a61cb923ef20efc665cb9f9bb50ac2f0c4b7f378d41" +checksum = "b0005d08a8f7b65fb8073cb697aa0b12b631ed251ce73d862ce50eeb52ce3b50" [[package]] name = "log" @@ -397,9 +402,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.3.4" +version = "2.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ee1c47aaa256ecabcaea351eae4a9b01ef39ed810004e298d2511ed284b1525" +checksum = "308cc39be01b73d0d18f82a0e7b2a3df85245f84af96fdddc5d202d27e47b86a" [[package]] name = "miniz_oxide" @@ -434,9 +439,9 @@ version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c03e3201148714c580c5cf1ef68b1ed4039203068193197834a43503164b8237" dependencies = [ - "proc-macro2 1.0.26", - "quote 1.0.9", - "syn 1.0.70", + "proc-macro2 1.0.36", + "quote 1.0.15", + "syn 1.0.86", ] [[package]] @@ -447,9 +452,9 @@ checksum = "a870300c30d4224cb16022a4660fd8084d6cb4d29618563c3016b50cc757d1e7" dependencies = [ "ntest_proc_macro_helper", "proc-macro-crate", - "proc-macro2 1.0.26", - "quote 1.0.9", - "syn 1.0.70", + "proc-macro2 1.0.36", + "quote 1.0.15", + "syn 1.0.86", ] [[package]] @@ -463,42 +468,42 @@ dependencies = [ [[package]] name = "pin-project" -version = "0.4.28" +version = "0.4.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "918192b5c59119d51e0cd221f4d49dde9112824ba717369e903c97d076083d0f" +checksum = "9615c18d31137579e9ff063499264ddc1278e7b1982757ebc111028c4d1dc909" dependencies = [ - "pin-project-internal 0.4.28", + "pin-project-internal 0.4.29", ] [[package]] name = "pin-project" -version = "1.0.7" +version = "1.0.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7509cc106041c40a4518d2af7a61530e1eed0e6285296a3d8c5472806ccc4a4" +checksum = "58ad3879ad3baf4e44784bc6a718a8698867bb991f8ce24d1bcbe2cfb4c3a75e" dependencies = [ - "pin-project-internal 1.0.7", + "pin-project-internal 1.0.10", ] [[package]] name = "pin-project-internal" -version = "0.4.28" +version = "0.4.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3be26700300be6d9d23264c73211d8190e755b6b5ca7a1b28230025511b52a5e" +checksum = "044964427019eed9d49d9d5bbce6047ef18f37100ea400912a9fa4a3523ab12a" dependencies = [ - "proc-macro2 1.0.26", - "quote 1.0.9", - "syn 1.0.70", + "proc-macro2 1.0.36", + "quote 1.0.15", + "syn 1.0.86", ] [[package]] name = "pin-project-internal" -version = "1.0.7" +version = "1.0.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48c950132583b500556b1efd71d45b319029f2b71518d979fcc208e16b42426f" +checksum = "744b6f092ba29c3650faf274db506afd39944f48420f6c86b17cfe0ee1cb36bb" dependencies = [ - "proc-macro2 1.0.26", - "quote 1.0.9", - "syn 1.0.70", + "proc-macro2 1.0.36", + "quote 1.0.15", + "syn 1.0.86", ] [[package]] @@ -509,9 +514,9 @@ checksum = "257b64915a082f7811703966789728173279bdebb956b143dbcd23f6f970a777" [[package]] name = "pin-project-lite" -version = "0.2.6" +version = "0.2.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc0e1f259c92177c30a4c9d177246edd0a3568b25756a977d0632cf8fa37e905" +checksum = "e280fbe77cc62c91527259e9442153f4688736748d24660126286329742b4c6c" [[package]] name = "pin-utils" @@ -521,15 +526,15 @@ checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" [[package]] name = "pkg-config" -version = "0.3.19" +version = "0.3.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3831453b3449ceb48b6d9c7ad7c96d5ea673e9b470a1dc578c2ce6521230884c" +checksum = "58893f751c9b0412871a09abd62ecd2a00298c6c83befa223ef98c52aef40cbe" [[package]] name = "ppv-lite86" -version = "0.2.10" +version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac74c624d6b2d21f425f752262f42188365d7b8ff1aff74c82e45136510a4857" +checksum = "eb9f9e6e233e5c4a35559a617bf40a4ec447db2e84c20b55a6f83167b7e57872" [[package]] name = "proc-macro-crate" @@ -540,18 +545,6 @@ dependencies = [ "toml", ] -[[package]] -name = "proc-macro-hack" -version = "0.5.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbf0c48bc1d91375ae5c3cd81e3722dff1abcf81a30960240640d223f59fe0e5" - -[[package]] -name = "proc-macro-nested" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc881b2c22681370c6a780e47af9840ef841837bc98118431d4e1868bd0c1086" - [[package]] name = "proc-macro2" version = "0.4.30" @@ -563,11 +556,11 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.26" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a152013215dca273577e18d2bf00fa862b89b24169fb78c4c95aeb07992c9cec" +checksum = "c7342d5883fbccae1cc37a2353b09c87c9b0f3afd73f5fb9bba687a1f733b029" dependencies = [ - "unicode-xid 0.2.1", + "unicode-xid 0.2.2", ] [[package]] @@ -618,11 +611,11 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.9" +version = "1.0.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3d0b9745dc2debf507c8422de05d7226cc1f0644216dfdfead988f9b1ab32a7" +checksum = "864d3e96a899863136fc6e99f3d7cae289dafe43bf2c5ac19b70df7210c0a145" dependencies = [ - "proc-macro2 1.0.26", + "proc-macro2 1.0.36", ] [[package]] @@ -650,25 +643,13 @@ version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" dependencies = [ - "getrandom 0.1.16", + "getrandom", "libc", "rand_chacha 0.2.2", "rand_core 0.5.1", "rand_hc 0.2.0", ] -[[package]] -name = "rand" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ef9e7e66b4468674bfcb0c81af8b7fa0bb154fa9f28eb840da5c447baeb8d7e" -dependencies = [ - "libc", - "rand_chacha 0.3.0", - "rand_core 0.6.2", - "rand_hc 0.3.0", -] - [[package]] name = "rand_chacha" version = "0.1.1" @@ -689,16 +670,6 @@ dependencies = [ "rand_core 0.5.1", ] -[[package]] -name = "rand_chacha" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e12735cf05c9e10bf21534da50a147b924d555dc7a547c42e6bb2d5b6017ae0d" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.2", -] - [[package]] name = "rand_core" version = "0.3.1" @@ -720,16 +691,7 @@ version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34cf66eb183df1c5876e2dcf6b13d57340741e8dc255b48e40a26de954d06ae7" -dependencies = [ - "getrandom 0.2.2", + "getrandom", ] [[package]] @@ -750,15 +712,6 @@ dependencies = [ "rand_core 0.5.1", ] -[[package]] -name = "rand_hc" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3190ef7066a446f2e7f42e239d161e905420ccab01eb967c9eb27d21b2322a73" -dependencies = [ - "rand_core 0.6.2", -] - [[package]] name = "rand_isaac" version = "0.1.1" @@ -823,18 +776,18 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.2.6" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8270314b5ccceb518e7e578952f0b72b88222d02e8f77f5ecf7abbb673539041" +checksum = "8383f39639269cde97d255a32bdb68c047337295414940c68bdd30c2e13203ff" dependencies = [ "bitflags", ] [[package]] name = "regex-syntax" -version = "0.6.23" +version = "0.6.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24d5f089152e60f62d28b835fbff2cd2e8dc0baf1ac13343bef92ab7eed84548" +checksum = "f497285884f3fcff424ffc933e56d7cbca511def0c9831a7f9b5f6153e3cc89b" [[package]] name = "remove_dir_all" @@ -859,15 +812,15 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.125" +version = "1.0.135" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "558dc50e1a5a5fa7112ca2ce4effcb321b0300c0d4ccf0776a9f60cd89031171" +checksum = "2cf9235533494ea2ddcdb794665461814781c53f19d87b76e571a1c35acbad2b" [[package]] name = "slab" -version = "0.4.3" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f173ac3d1a7e3b28003f40de0b5ce7fe2710f9b9dc3fc38664cebee46b3b6527" +checksum = "9def91fd1e018fe007022791f865d0ccc9b3a0d5001e01aabb8b40e46000afb5" [[package]] name = "syn" @@ -882,24 +835,24 @@ dependencies = [ [[package]] name = "syn" -version = "1.0.70" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9505f307c872bab8eb46f77ae357c8eba1fdacead58ee5a850116b1d7f82883" +checksum = "8a65b3f4ffa0092e9887669db0eae07941f023991ab58ea44da8fe8e2d511c6b" dependencies = [ - "proc-macro2 1.0.26", - "quote 1.0.9", - "unicode-xid 0.2.1", + "proc-macro2 1.0.36", + "quote 1.0.15", + "unicode-xid 0.2.2", ] [[package]] name = "tempfile" -version = "3.2.0" +version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dac1c663cfc93810f88aed9b8941d48cabf856a1b111c29a40439018d870eb22" +checksum = "5cdb1ef4eaeeaddc8fbd371e5017057064af0911902ef36b39801f67cc6d79e4" dependencies = [ "cfg-if", + "fastrand", "libc", - "rand 0.8.3", "redox_syscall", "remove_dir_all", "winapi", @@ -929,19 +882,18 @@ dependencies = [ "bytes 0.6.0", "futures-core", "memchr", - "pin-project-lite 0.2.6", + "pin-project-lite 0.2.8", ] [[package]] name = "tokio" -version = "1.5.0" +version = "1.15.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83f0c8e7c0addab50b663055baf787d0af7f413a46e6e7fb9559a4e4db7137a5" +checksum = "fbbf1c778ec206785635ce8ad57fe52b3009ae9e0c9f574a728f3049d3e55838" dependencies = [ - "autocfg 1.0.1", - "bytes 1.0.1", + "bytes 1.1.0", "memchr", - "pin-project-lite 0.2.6", + "pin-project-lite 0.2.8", ] [[package]] @@ -950,9 +902,9 @@ version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e44da00bfc73a25f814cd8d7e57a68a5c31b74b3152a0a1d1f590c97ed06265a" dependencies = [ - "proc-macro2 1.0.26", - "quote 1.0.9", - "syn 1.0.70", + "proc-macro2 1.0.36", + "quote 1.0.15", + "syn 1.0.86", ] [[package]] @@ -993,22 +945,22 @@ dependencies = [ "futures-core", "futures-sink", "log", - "pin-project-lite 0.2.6", + "pin-project-lite 0.2.8", "tokio 0.3.7", ] [[package]] name = "tokio-util" -version = "0.6.6" +version = "0.6.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "940a12c99365c31ea8dd9ba04ec1be183ffe4920102bb7122c2f515437601e8e" +checksum = "9e99e1983e5d376cd8eb4b66604d2e99e79f5bd988c3055891dcd8c9e2604cc0" dependencies = [ - "bytes 1.0.1", + "bytes 1.1.0", "futures-core", "futures-sink", "log", - "pin-project-lite 0.2.6", - "tokio 1.5.0", + "pin-project-lite 0.2.8", + "tokio 1.15.0", ] [[package]] @@ -1028,9 +980,9 @@ checksum = "fc72304796d0818e357ead4e000d19c9c174ab23dc11093ac919054d20a6a7fc" [[package]] name = "unicode-xid" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7fe0bb3479651439c9112f72b6c505038574c9fbb575ed1bf3b797fa39dd564" +checksum = "8ccb82d61f80a663efe1f787a51b16b5a51e3314d6ac365b08639f52387b33f3" [[package]] name = "wait-timeout" @@ -1047,12 +999,6 @@ version = "0.9.0+wasi-snapshot-preview1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" -[[package]] -name = "wasi" -version = "0.10.2+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd6fbd9a79829dd1ad0cc20627bf1ed606756a7f77edff7b66b7064f9cb327c6" - [[package]] name = "winapi" version = "0.3.9" From d0eceaca3046be2977298e060b14e58e6a2fb718 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Tue, 25 Jan 2022 17:18:14 +0100 Subject: [PATCH 03/34] Disable audit requirement There are no valid versions of Tokio <1.0 and no way to suppress specific issues in this action --- bors.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bors.toml b/bors.toml index 98990d39..5d49f6ca 100644 --- a/bors.toml +++ b/bors.toml @@ -10,7 +10,7 @@ status = [ "cargo hack check --all-targets --feature-powerset", "cargo fmt --check", "cargo clippy", - "cargo audit", + # "cargo audit", "cargo doc --cfg docsrs", ] delete_merged_branches = true From 50d5bb515cf2718c202f996077765ae4c17b9225 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Tue, 25 Jan 2022 17:22:21 +0100 Subject: [PATCH 04/34] Fix new clippy warnings --- src/codec/brotli/decoder.rs | 4 ++-- src/codec/brotli/encoder.rs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/codec/brotli/decoder.rs b/src/codec/brotli/decoder.rs index 392b4565..0eeab3f9 100644 --- a/src/codec/brotli/decoder.rs +++ b/src/codec/brotli/decoder.rs @@ -35,10 +35,10 @@ impl BrotliDecoder { let status = match BrotliDecompressStream( &mut in_buf.len(), &mut input_len, - &in_buf, + in_buf, &mut out_buf.len(), &mut output_len, - &mut out_buf, + out_buf, &mut 0, &mut self.state, ) { diff --git a/src/codec/brotli/encoder.rs b/src/codec/brotli/encoder.rs index 776246b6..c621464f 100644 --- a/src/codec/brotli/encoder.rs +++ b/src/codec/brotli/encoder.rs @@ -43,7 +43,7 @@ impl BrotliEncoder { in_buf, &mut input_len, &mut out_buf.len(), - &mut out_buf, + out_buf, &mut output_len, &mut None, &mut |_, _, _, _| (), From 1a077149ae70ccd790023424e1df3ae2b68246e0 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Tue, 25 Jan 2022 17:24:22 +0100 Subject: [PATCH 05/34] Unlock version of tarpaulin used --- .github/workflows/coverage.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index e9a9ecfe..ad426d66 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -14,7 +14,6 @@ jobs: toolchain: stable - uses: actions-rs/tarpaulin@v0.1 with: - version: 0.13.3 # v0.14.0 has issues with time v0.2.16 args: --locked --all-features From a71fadebf229e99b0cf8e4375a3ec4470bf85df4 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Tue, 25 Jan 2022 17:39:45 +0100 Subject: [PATCH 06/34] Update to zstd 0.9 --- Cargo.lock | 12 ++++++------ Cargo.toml | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 3499016a..a6dba69e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1032,18 +1032,18 @@ dependencies = [ [[package]] name = "zstd" -version = "0.8.3+zstd.1.5.0" +version = "0.9.2+zstd.1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ea7094c7b4a58fbd738eb0d4a2fc7684a0e6949a31597e074ffe20a07cbc2bf" +checksum = "2390ea1bf6c038c39674f22d95f0564725fc06034a47129179810b2fc58caa54" dependencies = [ "zstd-safe", ] [[package]] name = "zstd-safe" -version = "4.1.0+zstd.1.5.0" +version = "4.1.3+zstd.1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d30375f78e185ca4c91930f42ea2c0162f9aa29737032501f93b79266d985ae7" +checksum = "e99d81b99fb3c2c2c794e3fe56c305c63d5173a16a46b5850b07c935ffc7db79" dependencies = [ "libc", "zstd-sys", @@ -1051,9 +1051,9 @@ dependencies = [ [[package]] name = "zstd-sys" -version = "1.6.0+zstd.1.5.0" +version = "1.6.2+zstd.1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2141bed8922b427761470e6bbfeff255da94fa20b0bbeab0d9297fcaf71e3aa7" +checksum = "2daf2f248d9ea44454bfcb2516534e8b8ad2fc91bf818a1885495fc42bc8ac9f" dependencies = [ "cc", "libc", diff --git a/Cargo.toml b/Cargo.toml index 18f0594a..e2c5a28c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -44,8 +44,8 @@ flate2 = { version = "1.0.11", optional = true } futures-core = { version = "0.3.0", default-features = false } futures-io = { version = "0.3.0", default-features = false, features = ["std"], optional = true } pin-project-lite = "0.2.0" -libzstd = { package = "zstd", version = "0.8.3", optional = true, default-features = false } -zstd-safe = { version = "4.1.0", optional = true, default-features = false } +libzstd = { package = "zstd", version = "0.9.2", optional = true, default-features = false } +zstd-safe = { version = "4.1.3", optional = true, default-features = false } memchr = "2.2.1" tokio-02 = { package = "tokio", version = "0.2.21", optional = true, default-features = false } tokio-03 = { package = "tokio", version = "0.3.0", optional = true, default-features = false } From 36563e871a8405192d59194ab9ec706f01f15a12 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Tue, 25 Jan 2022 17:40:02 +0100 Subject: [PATCH 07/34] Bump version to 0.3.10 --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index a6dba69e..c18a5fd5 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -25,7 +25,7 @@ dependencies = [ [[package]] name = "async-compression" -version = "0.3.9" +version = "0.3.10" dependencies = [ "brotli", "bytes 0.5.6", diff --git a/Cargo.toml b/Cargo.toml index e2c5a28c..bcc6b6d0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "async-compression" -version = "0.3.9" +version = "0.3.10" authors = ["Wim Looman ", "Allen Bui "] edition = "2018" license = "MIT OR Apache-2.0" From 15a0ab8294af4e332570fa263f236d1317bb7fe5 Mon Sep 17 00:00:00 2001 From: Rotem Yaari Date: Mon, 8 Nov 2021 13:48:50 +0200 Subject: [PATCH 08/34] Update zstd dependency --- Cargo.lock | 12 ++++++------ Cargo.toml | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index c18a5fd5..706a5f0e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1032,18 +1032,18 @@ dependencies = [ [[package]] name = "zstd" -version = "0.9.2+zstd.1.5.1" +version = "0.10.0+zstd.1.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2390ea1bf6c038c39674f22d95f0564725fc06034a47129179810b2fc58caa54" +checksum = "3b1365becbe415f3f0fcd024e2f7b45bacfb5bdd055f0dc113571394114e7bdd" dependencies = [ "zstd-safe", ] [[package]] name = "zstd-safe" -version = "4.1.3+zstd.1.5.1" +version = "4.1.4+zstd.1.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e99d81b99fb3c2c2c794e3fe56c305c63d5173a16a46b5850b07c935ffc7db79" +checksum = "2f7cd17c9af1a4d6c24beb1cc54b17e2ef7b593dc92f19e9d9acad8b182bbaee" dependencies = [ "libc", "zstd-sys", @@ -1051,9 +1051,9 @@ dependencies = [ [[package]] name = "zstd-sys" -version = "1.6.2+zstd.1.5.1" +version = "1.6.3+zstd.1.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2daf2f248d9ea44454bfcb2516534e8b8ad2fc91bf818a1885495fc42bc8ac9f" +checksum = "fc49afa5c8d634e75761feda8c592051e7eeb4683ba827211eb0d731d3402ea8" dependencies = [ "cc", "libc", diff --git a/Cargo.toml b/Cargo.toml index bcc6b6d0..7d3568be 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -44,8 +44,8 @@ flate2 = { version = "1.0.11", optional = true } futures-core = { version = "0.3.0", default-features = false } futures-io = { version = "0.3.0", default-features = false, features = ["std"], optional = true } pin-project-lite = "0.2.0" -libzstd = { package = "zstd", version = "0.9.2", optional = true, default-features = false } -zstd-safe = { version = "4.1.3", optional = true, default-features = false } +libzstd = { package = "zstd", version = "0.10.0", optional = true, default-features = false } +zstd-safe = { version = "4.1.4", optional = true, default-features = false } memchr = "2.2.1" tokio-02 = { package = "tokio", version = "0.2.21", optional = true, default-features = false } tokio-03 = { package = "tokio", version = "0.3.0", optional = true, default-features = false } From 9dd06201dd8f7e00ffe8838127e1e0ca4d69db12 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Tue, 25 Jan 2022 18:04:46 +0100 Subject: [PATCH 09/34] Bump version to 0.3.11 --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 706a5f0e..1ced7fcd 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -25,7 +25,7 @@ dependencies = [ [[package]] name = "async-compression" -version = "0.3.10" +version = "0.3.11" dependencies = [ "brotli", "bytes 0.5.6", diff --git a/Cargo.toml b/Cargo.toml index 7d3568be..95fc4622 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "async-compression" -version = "0.3.10" +version = "0.3.11" authors = ["Wim Looman ", "Allen Bui "] edition = "2018" license = "MIT OR Apache-2.0" From 4577e830b153811b897d49b3ec26160fe72e1bd4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Miku=C5=82a?= Date: Wed, 26 Jan 2022 17:32:44 +0100 Subject: [PATCH 10/34] Use only `std` feature for `brotli` --- Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 95fc4622..1d9352d6 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -37,7 +37,7 @@ futures-write = ["futures-io"] [dependencies] xz2 = { version = "0.1.6", optional = true } -brotli = { version = "3.3.0", optional = true } +brotli = { version = "3.3.0", optional = true, default-features = false, features = ["std"] } bytes-05 = { package = "bytes", version = "0.5.0", optional = true } bzip2 = { version = "0.4.1" , optional = true } flate2 = { version = "1.0.11", optional = true } From b73c063f98d254b08a6826a71ac02f6885949f0d Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Wed, 26 Jan 2022 23:38:38 +0100 Subject: [PATCH 11/34] Bump version to 0.3.12 --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 1ced7fcd..5febc508 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -25,7 +25,7 @@ dependencies = [ [[package]] name = "async-compression" -version = "0.3.11" +version = "0.3.12" dependencies = [ "brotli", "bytes 0.5.6", diff --git a/Cargo.toml b/Cargo.toml index 1d9352d6..da5957ed 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "async-compression" -version = "0.3.11" +version = "0.3.12" authors = ["Wim Looman ", "Allen Bui "] edition = "2018" license = "MIT OR Apache-2.0" From d3dccc56d84a6856c0d0a7232c0e21f16e42ef8e Mon Sep 17 00:00:00 2001 From: Gregory Szorc Date: Sat, 16 Apr 2022 14:57:02 -0700 Subject: [PATCH 12/34] Bump zstd dependency libzstd 0.10 -> 0.11 and zstd-safe 4.1 -> 5.0. --- Cargo.lock | 12 ++++++------ Cargo.toml | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 5febc508..b9f2f651 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1032,18 +1032,18 @@ dependencies = [ [[package]] name = "zstd" -version = "0.10.0+zstd.1.5.2" +version = "0.11.1+zstd.1.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b1365becbe415f3f0fcd024e2f7b45bacfb5bdd055f0dc113571394114e7bdd" +checksum = "77a16b8414fde0414e90c612eba70985577451c4c504b99885ebed24762cb81a" dependencies = [ "zstd-safe", ] [[package]] name = "zstd-safe" -version = "4.1.4+zstd.1.5.2" +version = "5.0.1+zstd.1.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7cd17c9af1a4d6c24beb1cc54b17e2ef7b593dc92f19e9d9acad8b182bbaee" +checksum = "7c12659121420dd6365c5c3de4901f97145b79651fb1d25814020ed2ed0585ae" dependencies = [ "libc", "zstd-sys", @@ -1051,9 +1051,9 @@ dependencies = [ [[package]] name = "zstd-sys" -version = "1.6.3+zstd.1.5.2" +version = "2.0.1+zstd.1.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc49afa5c8d634e75761feda8c592051e7eeb4683ba827211eb0d731d3402ea8" +checksum = "9fd07cbbc53846d9145dbffdf6dd09a7a0aa52be46741825f5c97bdd4f73f12b" dependencies = [ "cc", "libc", diff --git a/Cargo.toml b/Cargo.toml index da5957ed..54922b1e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -44,8 +44,8 @@ flate2 = { version = "1.0.11", optional = true } futures-core = { version = "0.3.0", default-features = false } futures-io = { version = "0.3.0", default-features = false, features = ["std"], optional = true } pin-project-lite = "0.2.0" -libzstd = { package = "zstd", version = "0.10.0", optional = true, default-features = false } -zstd-safe = { version = "4.1.4", optional = true, default-features = false } +libzstd = { package = "zstd", version = "0.11.1", optional = true, default-features = false } +zstd-safe = { version = "5.0.1", optional = true, default-features = false } memchr = "2.2.1" tokio-02 = { package = "tokio", version = "0.2.21", optional = true, default-features = false } tokio-03 = { package = "tokio", version = "0.3.0", optional = true, default-features = false } From 674c32b9e54af050279498ee08dccdfb5be600c2 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Wed, 11 May 2022 12:39:14 +0200 Subject: [PATCH 13/34] Bump version to 0.3.13 --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b9f2f651..33a860b0 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -25,7 +25,7 @@ dependencies = [ [[package]] name = "async-compression" -version = "0.3.12" +version = "0.3.13" dependencies = [ "brotli", "bytes 0.5.6", diff --git a/Cargo.toml b/Cargo.toml index 54922b1e..c7366b16 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "async-compression" -version = "0.3.12" +version = "0.3.13" authors = ["Wim Looman ", "Allen Bui "] edition = "2018" license = "MIT OR Apache-2.0" From 7f14c8efef84d1c9c2496869ef8cbaf7f1e9d088 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Wed, 11 May 2022 13:32:38 +0200 Subject: [PATCH 14/34] Update proptest --- Cargo.lock | 192 ++++++++++++++++------------------------------------- Cargo.toml | 4 +- 2 files changed, 61 insertions(+), 135 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 33a860b0..2607a593 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -56,12 +56,6 @@ dependencies = [ "zstd-safe", ] -[[package]] -name = "autocfg" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d49d90015b3c36167a20fe2810c5cd875ad504b39cff3d4eae7977e6b7c1cb2" - [[package]] name = "autocfg" version = "1.0.1" @@ -170,15 +164,6 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" -[[package]] -name = "cloudabi" -version = "0.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddfc5b9aa5d4507acaf872de71051dfd0e309860e88966e1051e462a077aac4f" -dependencies = [ - "bitflags", -] - [[package]] name = "crc32fast" version = "1.3.1" @@ -215,12 +200,6 @@ version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" -[[package]] -name = "fuchsia-cprng" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a06f77d526c1a601b7c4cdd98f54b5eaabffc14d5f2f0296febdc7f357c6d3ba" - [[package]] name = "futures" version = "0.3.19" @@ -347,7 +326,18 @@ checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" dependencies = [ "cfg-if", "libc", - "wasi", + "wasi 0.9.0+wasi-snapshot-preview1", +] + +[[package]] +name = "getrandom" +version = "0.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9be70c98951c83b8d2f8f60d7065fa6d5146873094452a1008da8c2f1e4205ad" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.10.2+wasi-snapshot-preview1", ] [[package]] @@ -376,9 +366,9 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" [[package]] name = "libc" -version = "0.2.114" +version = "0.2.125" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0005d08a8f7b65fb8073cb697aa0b12b631ed251ce73d862ce50eeb52ce3b50" +checksum = "5916d2ae698f6de9bfb891ad7a8d65c09d232dc58cc4ac433c7da3b2fd84bc2b" [[package]] name = "log" @@ -413,7 +403,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a92518e98c078586bc6c934028adcca4c92a53d6a958196de835170a01d84e4b" dependencies = [ "adler", - "autocfg 1.0.1", + "autocfg", ] [[package]] @@ -463,7 +453,7 @@ version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9a64b1ec5cda2586e284722486d802acf1f7dbdc623e2bfc57e65ca1cd099290" dependencies = [ - "autocfg 1.0.1", + "autocfg", ] [[package]] @@ -565,18 +555,18 @@ dependencies = [ [[package]] name = "proptest" -version = "0.9.6" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01c477819b845fe023d33583ebf10c9f62518c8d79a0960ba5c36d6ac8a55a5b" +checksum = "1e0d9cc07f18492d879586c92b485def06bc850da3118075cd45d50e9c95b0e5" dependencies = [ "bit-set", "bitflags", "byteorder", "lazy_static", "num-traits", - "quick-error", - "rand 0.6.5", - "rand_chacha 0.1.1", + "quick-error 2.0.1", + "rand 0.8.5", + "rand_chacha 0.3.1", "rand_xorshift", "regex-syntax", "rusty-fork", @@ -585,9 +575,9 @@ dependencies = [ [[package]] name = "proptest-derive" -version = "0.1.2" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d31edb17edac73aeacc947bd61462dda15220584268896a58e12f053d767f15b" +checksum = "90b46295382dc76166cb7cf2bb4a97952464e4b7ed5a43e6cd34e1fec3349ddc" dependencies = [ "proc-macro2 0.4.30", "quote 0.6.13", @@ -600,6 +590,12 @@ version = "1.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" +[[package]] +name = "quick-error" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3" + [[package]] name = "quote" version = "0.6.13" @@ -618,46 +614,28 @@ dependencies = [ "proc-macro2 1.0.36", ] -[[package]] -name = "rand" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d71dacdc3c88c1fde3885a3be3fbab9f35724e6ce99467f7d9c5026132184ca" -dependencies = [ - "autocfg 0.1.7", - "libc", - "rand_chacha 0.1.1", - "rand_core 0.4.2", - "rand_hc 0.1.0", - "rand_isaac", - "rand_jitter", - "rand_os", - "rand_pcg", - "rand_xorshift", - "winapi", -] - [[package]] name = "rand" version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" dependencies = [ - "getrandom", + "getrandom 0.1.16", "libc", "rand_chacha 0.2.2", "rand_core 0.5.1", - "rand_hc 0.2.0", + "rand_hc", ] [[package]] -name = "rand_chacha" -version = "0.1.1" +name = "rand" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "556d3a1ca6600bfcbab7c7c91ccb085ac7fbbcd70e008a98742e7847f4f7bcef" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" dependencies = [ - "autocfg 0.1.7", - "rand_core 0.3.1", + "libc", + "rand_chacha 0.3.1", + "rand_core 0.6.3", ] [[package]] @@ -671,36 +649,31 @@ dependencies = [ ] [[package]] -name = "rand_core" +name = "rand_chacha" version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a6fdeb83b075e8266dcc8762c22776f6877a63111121f5f8c7411e5be7eed4b" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" dependencies = [ - "rand_core 0.4.2", + "ppv-lite86", + "rand_core 0.6.3", ] -[[package]] -name = "rand_core" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c33a3c44ca05fa6f1807d8e6743f3824e8509beca625669633be0acbdf509dc" - [[package]] name = "rand_core" version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" dependencies = [ - "getrandom", + "getrandom 0.1.16", ] [[package]] -name = "rand_hc" -version = "0.1.0" +name = "rand_core" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b40677c7be09ae76218dc623efbf7b18e34bced3f38883af07bb75630a21bc4" +checksum = "d34f1408f55294453790c48b2f1ebbb1c5b4b7563eb1f418bcfcfdbb06ebb4e7" dependencies = [ - "rand_core 0.3.1", + "getrandom 0.2.6", ] [[package]] @@ -712,66 +685,13 @@ dependencies = [ "rand_core 0.5.1", ] -[[package]] -name = "rand_isaac" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ded997c9d5f13925be2a6fd7e66bf1872597f759fd9dd93513dd7e92e5a5ee08" -dependencies = [ - "rand_core 0.3.1", -] - -[[package]] -name = "rand_jitter" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1166d5c91dc97b88d1decc3285bb0a99ed84b05cfd0bc2341bdf2d43fc41e39b" -dependencies = [ - "libc", - "rand_core 0.4.2", - "winapi", -] - -[[package]] -name = "rand_os" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b75f676a1e053fc562eafbb47838d67c84801e38fc1ba459e8f180deabd5071" -dependencies = [ - "cloudabi", - "fuchsia-cprng", - "libc", - "rand_core 0.4.2", - "rdrand", - "winapi", -] - -[[package]] -name = "rand_pcg" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abf9b09b01790cfe0364f52bf32995ea3c39f4d2dd011eac241d2914146d0b44" -dependencies = [ - "autocfg 0.1.7", - "rand_core 0.4.2", -] - [[package]] name = "rand_xorshift" -version = "0.1.1" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbf7e9e623549b0e21f6e97cf8ecf247c1a8fd2e8a992ae265314300b2455d5c" +checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" dependencies = [ - "rand_core 0.3.1", -] - -[[package]] -name = "rdrand" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "678054eb77286b51581ba43620cc911abf02758c91f93f479767aed0f90458b2" -dependencies = [ - "rand_core 0.3.1", + "rand_core 0.6.3", ] [[package]] @@ -800,12 +720,12 @@ dependencies = [ [[package]] name = "rusty-fork" -version = "0.2.2" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dd93264e10c577503e926bd1430193eeb5d21b059148910082245309b424fae" +checksum = "cb3dcc6e454c328bb824492db107ab7c0ae8fcffe4ad210136ef014458c1bc4f" dependencies = [ "fnv", - "quick-error", + "quick-error 1.2.3", "tempfile", "wait-timeout", ] @@ -878,7 +798,7 @@ version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "46409491c9375a693ce7032101970a54f8a2010efb77e13f70788f0d84489e39" dependencies = [ - "autocfg 1.0.1", + "autocfg", "bytes 0.6.0", "futures-core", "memchr", @@ -999,6 +919,12 @@ version = "0.9.0+wasi-snapshot-preview1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" +[[package]] +name = "wasi" +version = "0.10.2+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd6fbd9a79829dd1ad0cc20627bf1ed606756a7f77edff7b66b7064f9cb327c6" + [[package]] name = "winapi" version = "0.3.9" diff --git a/Cargo.toml b/Cargo.toml index c7366b16..43cd458e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -52,8 +52,8 @@ tokio-03 = { package = "tokio", version = "0.3.0", optional = true, default-feat tokio = { version = "1.0.0", optional = true, default-features = false } [dev-dependencies] -proptest = "0.9.4" -proptest-derive = "0.1.2" +proptest = "1.0.0" +proptest-derive = "0.3.0" rand = "0.7.2" futures = "0.3.5" futures-test = "0.3.5" From 1c181e213d89992fdd84fedb238af1b800815fa0 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Wed, 11 May 2022 13:36:23 +0200 Subject: [PATCH 15/34] Update rand --- Cargo.lock | 76 +++++++----------------------------------------------- Cargo.toml | 2 +- 2 files changed, 10 insertions(+), 68 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 2607a593..7985888c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -43,7 +43,7 @@ dependencies = [ "pin-project-lite 0.2.8", "proptest", "proptest-derive", - "rand 0.7.3", + "rand", "tokio 0.2.25", "tokio 0.3.7", "tokio 1.15.0", @@ -318,17 +318,6 @@ dependencies = [ "pin-project 0.4.29", ] -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - [[package]] name = "getrandom" version = "0.2.6" @@ -337,7 +326,7 @@ checksum = "9be70c98951c83b8d2f8f60d7065fa6d5146873094452a1008da8c2f1e4205ad" dependencies = [ "cfg-if", "libc", - "wasi 0.10.2+wasi-snapshot-preview1", + "wasi", ] [[package]] @@ -565,8 +554,8 @@ dependencies = [ "lazy_static", "num-traits", "quick-error 2.0.1", - "rand 0.8.5", - "rand_chacha 0.3.1", + "rand", + "rand_chacha", "rand_xorshift", "regex-syntax", "rusty-fork", @@ -614,19 +603,6 @@ dependencies = [ "proc-macro2 1.0.36", ] -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - [[package]] name = "rand" version = "0.8.5" @@ -634,18 +610,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" dependencies = [ "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.3", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", + "rand_chacha", + "rand_core", ] [[package]] @@ -655,16 +621,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" dependencies = [ "ppv-lite86", - "rand_core 0.6.3", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", + "rand_core", ] [[package]] @@ -673,16 +630,7 @@ version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d34f1408f55294453790c48b2f1ebbb1c5b4b7563eb1f418bcfcfdbb06ebb4e7" dependencies = [ - "getrandom 0.2.6", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", + "getrandom", ] [[package]] @@ -691,7 +639,7 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" dependencies = [ - "rand_core 0.6.3", + "rand_core", ] [[package]] @@ -913,12 +861,6 @@ dependencies = [ "libc", ] -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - [[package]] name = "wasi" version = "0.10.2+wasi-snapshot-preview1" diff --git a/Cargo.toml b/Cargo.toml index 43cd458e..c78da8c3 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -54,7 +54,7 @@ tokio = { version = "1.0.0", optional = true, default-features = false } [dev-dependencies] proptest = "1.0.0" proptest-derive = "0.3.0" -rand = "0.7.2" +rand = "0.8.5" futures = "0.3.5" futures-test = "0.3.5" ntest = "0.7.3" From 08e49a1793a2d048a6a1a52bc633c918ad1bfce1 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Wed, 11 May 2022 13:36:53 +0200 Subject: [PATCH 16/34] Update ntest --- Cargo.lock | 41 +++++++++++++++++++++++++++++++---------- Cargo.toml | 2 +- 2 files changed, 32 insertions(+), 11 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 7985888c..0384ce44 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -397,9 +397,9 @@ dependencies = [ [[package]] name = "ntest" -version = "0.7.3" +version = "0.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "984caf6c8aa869418ef88062fc685d07d50c04308e63f7eaff6a395b1f5aff33" +checksum = "5c544e496c816f0a59645c0bb69097e453df203954ae2ed4b3ac4251fad69d44" dependencies = [ "ntest_proc_macro_helper", "ntest_test_cases", @@ -408,15 +408,15 @@ dependencies = [ [[package]] name = "ntest_proc_macro_helper" -version = "0.7.3" +version = "0.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "115562228962147ca51748d19446a4261535a7b6a7b5ff02681e527dcefc22f7" +checksum = "8f52e34b414605b77efc95c3f0ecef01df0c324bcc7f68d9a9cb7a7552777e52" [[package]] name = "ntest_test_cases" -version = "0.7.3" +version = "0.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c03e3201148714c580c5cf1ef68b1ed4039203068193197834a43503164b8237" +checksum = "99a81eb400abc87063f829560bc5c5c835177703b83d1cd991960db0b2a00abe" dependencies = [ "proc-macro2 1.0.36", "quote 1.0.15", @@ -425,9 +425,9 @@ dependencies = [ [[package]] name = "ntest_timeout" -version = "0.7.3" +version = "0.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a870300c30d4224cb16022a4660fd8084d6cb4d29618563c3016b50cc757d1e7" +checksum = "b10db009e117aca57cbfb70ac332348f9a89d09ff7204497c283c0f7a0c96323" dependencies = [ "ntest_proc_macro_helper", "proc-macro-crate", @@ -517,10 +517,11 @@ checksum = "eb9f9e6e233e5c4a35559a617bf40a4ec447db2e84c20b55a6f83167b7e57872" [[package]] name = "proc-macro-crate" -version = "0.1.5" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d6ea3c4595b96363c13943497db34af4460fb474a95c43f4446ad341b8c9785" +checksum = "e17d47ce914bf4de440332250b0edd23ce48c005f59fab39d3335866b114f11a" dependencies = [ + "thiserror", "toml", ] @@ -726,6 +727,26 @@ dependencies = [ "winapi", ] +[[package]] +name = "thiserror" +version = "1.0.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bd829fe32373d27f76265620b5309d0340cb8550f523c1dda251d6298069069a" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0396bc89e626244658bef819e22d0cc459e795a5ebe878e6ec336d1674a8d79a" +dependencies = [ + "proc-macro2 1.0.36", + "quote 1.0.15", + "syn 1.0.86", +] + [[package]] name = "tokio" version = "0.2.25" diff --git a/Cargo.toml b/Cargo.toml index c78da8c3..2bc87d9a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -57,7 +57,7 @@ proptest-derive = "0.3.0" rand = "0.8.5" futures = "0.3.5" futures-test = "0.3.5" -ntest = "0.7.3" +ntest = "0.7.5" bytes-05 = { package = "bytes", version = "0.5.0" } bytes-06 = { package = "bytes", version = "0.6.0" } bytes = "1.0.0" From 33f0b716a9112fe290d9fd84da5342ad6465dc51 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Wed, 11 May 2022 14:20:53 +0200 Subject: [PATCH 17/34] Remove unused futures-codec dependency --- Cargo.lock | 37 ++----------------------------------- Cargo.toml | 1 - 2 files changed, 2 insertions(+), 36 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 0384ce44..f25e11f1 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -37,7 +37,6 @@ dependencies = [ "futures-core", "futures-io", "futures-test", - "futures_codec", "memchr", "ntest", "pin-project-lite 0.2.8", @@ -284,7 +283,7 @@ dependencies = [ "futures-sink", "futures-task", "futures-util", - "pin-project 1.0.10", + "pin-project", "pin-utils", ] @@ -306,18 +305,6 @@ dependencies = [ "slab", ] -[[package]] -name = "futures_codec" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce54d63f8b0c75023ed920d46fd71d0cbbb830b0ee012726b5b4f506fb6dea5b" -dependencies = [ - "bytes 0.5.6", - "futures", - "memchr", - "pin-project 0.4.29", -] - [[package]] name = "getrandom" version = "0.2.6" @@ -445,33 +432,13 @@ dependencies = [ "autocfg", ] -[[package]] -name = "pin-project" -version = "0.4.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9615c18d31137579e9ff063499264ddc1278e7b1982757ebc111028c4d1dc909" -dependencies = [ - "pin-project-internal 0.4.29", -] - [[package]] name = "pin-project" version = "1.0.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "58ad3879ad3baf4e44784bc6a718a8698867bb991f8ce24d1bcbe2cfb4c3a75e" dependencies = [ - "pin-project-internal 1.0.10", -] - -[[package]] -name = "pin-project-internal" -version = "0.4.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "044964427019eed9d49d9d5bbce6047ef18f37100ea400912a9fa4a3523ab12a" -dependencies = [ - "proc-macro2 1.0.36", - "quote 1.0.15", - "syn 1.0.86", + "pin-project-internal", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 2bc87d9a..5b11f157 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -68,7 +68,6 @@ tokio-util-03 = { package = "tokio-util", version = "0.3.0", default-features = tokio-util-04 = { package = "tokio-util", version = "0.4.0", default-features = false, features = ["io"] } tokio-util-05 = { package = "tokio-util", version = "0.5.0", default-features = false, features = ["io"] } tokio-util-06 = { package = "tokio-util", version = "0.6.0", default-features = false, features = ["io"] } -futures_codec = { version = "0.4.1", default-features = false } [[test]] name = "brotli" From 63ea354f9c63d7498e1ea9a93d1d989105f78d0e Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Wed, 11 May 2022 14:21:08 +0200 Subject: [PATCH 18/34] Add cargo-deny config --- deny.toml | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 deny.toml diff --git a/deny.toml b/deny.toml new file mode 100644 index 00000000..c6832572 --- /dev/null +++ b/deny.toml @@ -0,0 +1,32 @@ +[advisories] +ignore = [ + # tokio 0.2 and 0.3 are both perma-vulnerable to these two advisories, + # will be removed once support for them is dropped + "RUSTSEC-2021-0072", + "RUSTSEC-2021-0124", +] + +[licenses] +unlicensed = "deny" +allow = [ + "MIT", + "Apache-2.0", + "BSD-3-Clause", +] +default = "deny" + +[bans] +multiple-versions = "warn" +skip = [ + # Used in the stream migration docs + { name = "tokio-util", version = "0.3" }, + { name = "tokio-util", version = "0.4" }, + { name = "tokio-util", version = "0.5" }, + { name = "tokio-util", version = "0.6" }, +] +skip-tree = [ + { name = "tokio", version = "0.2" }, + { name = "tokio", version = "0.3" }, + { name = "proptest", version = "1.0" }, + { name = "proptest-derive", version = "0.3" }, +] From cf23c9b4d2ef6d3a9dc5a3558ed4b9de6a45cea5 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Wed, 11 May 2022 14:27:30 +0200 Subject: [PATCH 19/34] Migrate from cargo audit to cargo deny --- .github/workflows/audit.yml | 20 -------------------- .github/workflows/deny.yml | 30 ++++++++++++++++++++++++++++++ bors.toml | 2 +- 3 files changed, 31 insertions(+), 21 deletions(-) delete mode 100644 .github/workflows/audit.yml create mode 100644 .github/workflows/deny.yml diff --git a/.github/workflows/audit.yml b/.github/workflows/audit.yml deleted file mode 100644 index cf78c4f0..00000000 --- a/.github/workflows/audit.yml +++ /dev/null @@ -1,20 +0,0 @@ -name: audit - -env: - RUST_BACKTRACE: 1 - -jobs: - audit: - name: cargo audit - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v1 - - uses: actions-rs/audit-check@v1 - with: - token: ${{ secrets.GITHUB_TOKEN }} - -on: - push: - branches: [staging, trying] - pull_request: - branches: [prīmum] diff --git a/.github/workflows/deny.yml b/.github/workflows/deny.yml new file mode 100644 index 00000000..c6c15a03 --- /dev/null +++ b/.github/workflows/deny.yml @@ -0,0 +1,30 @@ +name: deny + +env: + RUST_BACKTRACE: 1 + +jobs: + cargo-deny-advisories: + name: cargo deny advisories + runs-on: ubuntu-latest + continue-on-error: true + steps: + - uses: actions/checkout@v2 + - uses: EmbarkStudios/cargo-deny-action@v1 + with: + command: check advisories + + cargo-deny-licenses: + name: cargo deny bans licenses sources + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: EmbarkStudios/cargo-deny-action@v1 + with: + command: check bans licenses sources + +on: + push: + branches: [staging, trying] + pull_request: + branches: [prīmum] diff --git a/bors.toml b/bors.toml index 5d49f6ca..b0a311e6 100644 --- a/bors.toml +++ b/bors.toml @@ -10,7 +10,7 @@ status = [ "cargo hack check --all-targets --feature-powerset", "cargo fmt --check", "cargo clippy", - # "cargo audit", + "cargo deny bans licenses sources", "cargo doc --cfg docsrs", ] delete_merged_branches = true From eb1d0cc2d36b498da200f25e6141fb6d1eb0cd90 Mon Sep 17 00:00:00 2001 From: eta Date: Thu, 12 May 2022 18:32:05 +0100 Subject: [PATCH 20/34] bufread::generic::Decoder: don't reinitialize on reader EOF If `multiple_members` is enabled, the `bufread::generic::Decoder` will attempt to reinitialise the decoder inside `State::Flushing`, even if the reason it entered that state was due to the reader returning an EOF. This will result in an attempt to read past EOF, which is highly undesirable to say the least. To fix this, force `multiple_members` to `false` when we get an EOF condition from the reader. --- src/futures/bufread/generic/decoder.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/futures/bufread/generic/decoder.rs b/src/futures/bufread/generic/decoder.rs index ff39b163..d19daae5 100644 --- a/src/futures/bufread/generic/decoder.rs +++ b/src/futures/bufread/generic/decoder.rs @@ -70,6 +70,9 @@ impl Decoder { State::Decoding => { let input = ready!(this.reader.as_mut().poll_fill_buf(cx))?; if input.is_empty() { + // Avoid attempting to reinitialise the decoder if the reader + // has returned EOF. + *this.multiple_members = false; State::Flushing } else { let mut input = PartialBuffer::new(input); From 701a3a34511a2ea5916b95de3b99d89bdac7ad0f Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Fri, 13 May 2022 10:57:54 +0200 Subject: [PATCH 21/34] Add assertion that we do not read past EOF --- tests/utils/impls.rs | 18 ++-- tests/utils/mod.rs | 3 +- tests/utils/track_eof.rs | 184 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 196 insertions(+), 9 deletions(-) create mode 100644 tests/utils/track_eof.rs diff --git a/tests/utils/impls.rs b/tests/utils/impls.rs index a1b1ac8c..18cea2eb 100644 --- a/tests/utils/impls.rs +++ b/tests/utils/impls.rs @@ -13,13 +13,13 @@ pub mod futures { pub mod bufread { pub use futures::io::AsyncBufRead; - use crate::utils::InputStream; + use crate::utils::{InputStream, TrackEof}; use futures::stream::{StreamExt as _, TryStreamExt as _}; pub fn from(input: &InputStream) -> impl AsyncBufRead { // By using the stream here we ensure that each chunk will require a separate // read/poll_fill_buf call to process to help test reading multiple chunks. - input.stream().map(Ok).into_async_read() + TrackEof::new(input.stream().map(Ok).into_async_read()) } } @@ -100,13 +100,13 @@ pub mod tokio_02 { pub mod bufread { pub use tokio_02::io::AsyncBufRead; - use crate::utils::InputStream; + use crate::utils::{InputStream, TrackEof}; use tokio_02::io::stream_reader; pub fn from(input: &InputStream) -> impl AsyncBufRead { // By using the stream here we ensure that each chunk will require a separate // read/poll_fill_buf call to process to help test reading multiple chunks. - stream_reader(input.bytes_05_stream()) + TrackEof::new(stream_reader(input.bytes_05_stream())) } } @@ -169,14 +169,14 @@ pub mod tokio_02 { #[cfg(feature = "tokio-03")] pub mod tokio_03 { pub mod bufread { - use crate::utils::InputStream; + use crate::utils::{InputStream, TrackEof}; pub use tokio_03::io::AsyncBufRead; use tokio_util_04::io::StreamReader; pub fn from(input: &InputStream) -> impl AsyncBufRead { // By using the stream here we ensure that each chunk will require a separate // read/poll_fill_buf call to process to help test reading multiple chunks. - StreamReader::new(input.bytes_05_stream()) + TrackEof::new(StreamReader::new(input.bytes_05_stream())) } } @@ -239,7 +239,7 @@ pub mod tokio_03 { #[cfg(feature = "tokio")] pub mod tokio { pub mod bufread { - use crate::utils::InputStream; + use crate::utils::{InputStream, TrackEof}; use bytes::Bytes; use futures::stream::StreamExt; pub use tokio::io::AsyncBufRead; @@ -248,7 +248,9 @@ pub mod tokio { pub fn from(input: &InputStream) -> impl AsyncBufRead { // By using the stream here we ensure that each chunk will require a separate // read/poll_fill_buf call to process to help test reading multiple chunks. - StreamReader::new(input.stream().map(Bytes::from).map(std::io::Result::Ok)) + TrackEof::new(StreamReader::new( + input.stream().map(Bytes::from).map(std::io::Result::Ok), + )) } } diff --git a/tests/utils/mod.rs b/tests/utils/mod.rs index a83a1506..0f6de461 100644 --- a/tests/utils/mod.rs +++ b/tests/utils/mod.rs @@ -8,13 +8,14 @@ mod tokio_03_ext; #[cfg(feature = "tokio")] mod tokio_ext; mod track_closed; +mod track_eof; #[macro_use] mod test_cases; pub mod algos; pub mod impls; -pub use self::{input_stream::InputStream, track_closed::TrackClosed}; +pub use self::{input_stream::InputStream, track_closed::TrackClosed, track_eof::TrackEof}; pub use async_compression::Level; pub use futures::{executor::block_on, pin_mut, stream::Stream}; pub use std::{future::Future, io::Result, iter::FromIterator, pin::Pin}; diff --git a/tests/utils/track_eof.rs b/tests/utils/track_eof.rs new file mode 100644 index 00000000..d2101d13 --- /dev/null +++ b/tests/utils/track_eof.rs @@ -0,0 +1,184 @@ +#[cfg_attr(not(feature = "all-implementations"), allow(unused))] +use std::{ + io::Result, + pin::Pin, + task::{Context, Poll}, +}; + +pub struct TrackEof { + inner: R, + eof: bool, +} + +impl TrackEof { + pub fn new(inner: R) -> Self { + Self { inner, eof: false } + } + + pub fn project(self: Pin<&mut Self>) -> (Pin<&mut R>, &mut bool) { + let Self { inner, eof } = Pin::into_inner(self); + (Pin::new(inner), eof) + } +} + +#[cfg(feature = "futures-io")] +impl futures::io::AsyncRead for TrackEof { + fn poll_read(self: Pin<&mut Self>, cx: &mut Context, buf: &mut [u8]) -> Poll> { + let (inner, eof) = self.project(); + assert!(!*eof); + match inner.poll_read(cx, buf) { + Poll::Ready(Ok(0)) => { + if !buf.is_empty() { + *eof = true; + } + Poll::Ready(Ok(0)) + } + other => other, + } + } +} + +#[cfg(feature = "futures-io")] +impl futures::io::AsyncBufRead for TrackEof { + fn poll_fill_buf(self: Pin<&mut Self>, cx: &mut Context) -> Poll> { + let (inner, eof) = self.project(); + assert!(!*eof); + match inner.poll_fill_buf(cx) { + Poll::Ready(Ok(buf)) => { + if buf.is_empty() { + *eof = true; + } + Poll::Ready(Ok(buf)) + } + other => other, + } + } + + fn consume(self: Pin<&mut Self>, amt: usize) { + self.project().0.consume(amt) + } +} + +#[cfg(feature = "tokio-02")] +impl tokio_02::io::AsyncRead for TrackEof { + fn poll_read(self: Pin<&mut Self>, cx: &mut Context, buf: &mut [u8]) -> Poll> { + let (inner, eof) = self.project(); + assert!(!*eof); + match inner.poll_read(cx, buf) { + Poll::Ready(Ok(0)) => { + if !buf.is_empty() { + *eof = true; + } + Poll::Ready(Ok(0)) + } + other => other, + } + } +} + +#[cfg(feature = "tokio-02")] +impl tokio_02::io::AsyncBufRead for TrackEof { + fn poll_fill_buf(self: Pin<&mut Self>, cx: &mut Context) -> Poll> { + let (inner, eof) = self.project(); + assert!(!*eof); + match inner.poll_fill_buf(cx) { + Poll::Ready(Ok(buf)) => { + if buf.is_empty() { + *eof = true; + } + Poll::Ready(Ok(buf)) + } + other => other, + } + } + + fn consume(self: Pin<&mut Self>, amt: usize) { + self.project().0.consume(amt) + } +} + +#[cfg(feature = "tokio-03")] +impl tokio_03::io::AsyncRead for TrackEof { + fn poll_read( + self: Pin<&mut Self>, + cx: &mut Context, + buf: &mut tokio_03::io::ReadBuf, + ) -> Poll> { + let (inner, eof) = self.project(); + assert!(!*eof); + let len = buf.filled().len(); + match inner.poll_read(cx, buf) { + Poll::Ready(Ok(())) => { + if buf.filled().len() == len && buf.remaining() > 0 { + *eof = true; + } + Poll::Ready(Ok(())) + } + other => other, + } + } +} + +#[cfg(feature = "tokio-03")] +impl tokio_03::io::AsyncBufRead for TrackEof { + fn poll_fill_buf(self: Pin<&mut Self>, cx: &mut Context) -> Poll> { + let (inner, eof) = self.project(); + assert!(!*eof); + match inner.poll_fill_buf(cx) { + Poll::Ready(Ok(buf)) => { + if buf.is_empty() { + *eof = true; + } + Poll::Ready(Ok(buf)) + } + other => other, + } + } + + fn consume(self: Pin<&mut Self>, amt: usize) { + self.project().0.consume(amt) + } +} + +#[cfg(feature = "tokio")] +impl tokio::io::AsyncRead for TrackEof { + fn poll_read( + self: Pin<&mut Self>, + cx: &mut Context, + buf: &mut tokio::io::ReadBuf, + ) -> Poll> { + let (inner, eof) = self.project(); + assert!(!*eof); + let len = buf.filled().len(); + match inner.poll_read(cx, buf) { + Poll::Ready(Ok(())) => { + if buf.filled().len() == len && buf.remaining() > 0 { + *eof = true; + } + Poll::Ready(Ok(())) + } + other => other, + } + } +} + +#[cfg(feature = "tokio")] +impl tokio::io::AsyncBufRead for TrackEof { + fn poll_fill_buf(self: Pin<&mut Self>, cx: &mut Context) -> Poll> { + let (inner, eof) = self.project(); + assert!(!*eof); + match inner.poll_fill_buf(cx) { + Poll::Ready(Ok(buf)) => { + if buf.is_empty() { + *eof = true; + } + Poll::Ready(Ok(buf)) + } + other => other, + } + } + + fn consume(self: Pin<&mut Self>, amt: usize) { + self.project().0.consume(amt) + } +} From e7246738762de34bbb820662c3923f8f2610ac95 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Sun, 15 May 2022 14:40:17 +0200 Subject: [PATCH 22/34] Don't reinitialize on reader EOF for other implementations --- src/tokio/bufread/generic/decoder.rs | 3 +++ src/tokio_02/bufread/generic/decoder.rs | 3 +++ src/tokio_03/bufread/generic/decoder.rs | 3 +++ 3 files changed, 9 insertions(+) diff --git a/src/tokio/bufread/generic/decoder.rs b/src/tokio/bufread/generic/decoder.rs index e9ef44e8..2f4d8c7f 100644 --- a/src/tokio/bufread/generic/decoder.rs +++ b/src/tokio/bufread/generic/decoder.rs @@ -70,6 +70,9 @@ impl Decoder { State::Decoding => { let input = ready!(this.reader.as_mut().poll_fill_buf(cx))?; if input.is_empty() { + // Avoid attempting to reinitialise the decoder if the reader + // has returned EOF. + *this.multiple_members = false; State::Flushing } else { let mut input = PartialBuffer::new(input); diff --git a/src/tokio_02/bufread/generic/decoder.rs b/src/tokio_02/bufread/generic/decoder.rs index 7e876770..38dc068d 100644 --- a/src/tokio_02/bufread/generic/decoder.rs +++ b/src/tokio_02/bufread/generic/decoder.rs @@ -70,6 +70,9 @@ impl Decoder { State::Decoding => { let input = ready!(this.reader.as_mut().poll_fill_buf(cx))?; if input.is_empty() { + // Avoid attempting to reinitialise the decoder if the reader + // has returned EOF. + *this.multiple_members = false; State::Flushing } else { let mut input = PartialBuffer::new(input); diff --git a/src/tokio_03/bufread/generic/decoder.rs b/src/tokio_03/bufread/generic/decoder.rs index b643c636..796218c9 100644 --- a/src/tokio_03/bufread/generic/decoder.rs +++ b/src/tokio_03/bufread/generic/decoder.rs @@ -70,6 +70,9 @@ impl Decoder { State::Decoding => { let input = ready!(this.reader.as_mut().poll_fill_buf(cx))?; if input.is_empty() { + // Avoid attempting to reinitialise the decoder if the reader + // has returned EOF. + *this.multiple_members = false; State::Flushing } else { let mut input = PartialBuffer::new(input); From 149c9f8648cef5306b8120b326431f129f726c25 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Thu, 19 May 2022 17:01:51 +0200 Subject: [PATCH 23/34] Bump version to 0.3.14 --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f25e11f1..5c029f4d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -25,7 +25,7 @@ dependencies = [ [[package]] name = "async-compression" -version = "0.3.13" +version = "0.3.14" dependencies = [ "brotli", "bytes 0.5.6", diff --git a/Cargo.toml b/Cargo.toml index 5b11f157..d36de299 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "async-compression" -version = "0.3.13" +version = "0.3.14" authors = ["Wim Looman ", "Allen Bui "] edition = "2018" license = "MIT OR Apache-2.0" From c02da1c68209e08d991ef55e357897beb7807c82 Mon Sep 17 00:00:00 2001 From: Jiahao XU Date: Sun, 28 Aug 2022 19:16:33 +1000 Subject: [PATCH 24/34] Add dependabot Signed-off-by: Jiahao XU --- .github/dependabot.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 00000000..8bb64082 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,14 @@ +# Dependabot dependency version checks / updates + +version: 2 +updates: + - package-ecosystem: "github-actions" + # Workflow files stored in the + # default location of `.github/workflows` + directory: "/" + schedule: + interval: "daily" + - package-ecosystem: "cargo" + directory: "/" + schedule: + interval: "daily" From 189f730ec74b5ac6a50171c1be6a1d384c64e81c Mon Sep 17 00:00:00 2001 From: hdhoang Date: Mon, 29 Aug 2022 13:38:56 +0700 Subject: [PATCH 25/34] zstd: surface implicit default level `3` via libzstd constant instead of c-like flag `0` --- src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib.rs b/src/lib.rs index 31d921d9..108cb859 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -244,7 +244,7 @@ impl Level { Self::Fastest => 1, Self::Best => 21, Self::Precise(quality) => quality.min(21) as i32, - Self::Default => 0, + Self::Default => libzstd::DEFAULT_COMPRESSION_LEVEL, } } From 0a47de98594b0308952dc71273857f4a99da4ec7 Mon Sep 17 00:00:00 2001 From: Jiahao XU Date: Tue, 30 Aug 2022 22:48:21 +1000 Subject: [PATCH 26/34] Add `rebase-strategy: "disabled"` to dependabot Signed-off-by: Jiahao XU --- .github/dependabot.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 8bb64082..03194e2b 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -8,7 +8,9 @@ updates: directory: "/" schedule: interval: "daily" + rebase-strategy: "disabled" - package-ecosystem: "cargo" directory: "/" schedule: interval: "daily" + rebase-strategy: "disabled" From a456f2cbb621c5d456cc287406cd4abebc4bcd5d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 30 Aug 2022 13:30:45 +0000 Subject: [PATCH 27/34] Bump codecov/codecov-action from 1 to 3 Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 1 to 3. - [Release notes](https://github.com/codecov/codecov-action/releases) - [Changelog](https://github.com/codecov/codecov-action/blob/master/CHANGELOG.md) - [Commits](https://github.com/codecov/codecov-action/compare/v1...v3) --- updated-dependencies: - dependency-name: codecov/codecov-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/coverage.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index ad426d66..e404c9bb 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -19,7 +19,7 @@ jobs: --all-features -- --skip 'proptest::' - - uses: codecov/codecov-action@v1 + - uses: codecov/codecov-action@v3 on: push: From 404687f1f45b80e341d23f7273f027902d5be9e7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 30 Aug 2022 13:30:49 +0000 Subject: [PATCH 28/34] Bump actions/checkout from 2 to 3 Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 3. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v2...v3) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/base.yml | 2 +- .github/workflows/coverage.yml | 2 +- .github/workflows/deny.yml | 4 ++-- .github/workflows/docs.yml | 2 +- .github/workflows/exhaustive.yml | 8 ++++---- .github/workflows/lint.yml | 4 ++-- .github/workflows/nightly.yml | 6 +++--- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/base.yml b/.github/workflows/base.yml index ca5cc798..b59d1309 100644 --- a/.github/workflows/base.yml +++ b/.github/workflows/base.yml @@ -8,7 +8,7 @@ jobs: name: cargo test runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 - uses: actions-rs/cargo@v1 with: diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index ad426d66..1d3038e8 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -8,7 +8,7 @@ jobs: name: codecov runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: actions-rs/toolchain@v1 with: toolchain: stable diff --git a/.github/workflows/deny.yml b/.github/workflows/deny.yml index c6c15a03..1235d12e 100644 --- a/.github/workflows/deny.yml +++ b/.github/workflows/deny.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest continue-on-error: true steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: EmbarkStudios/cargo-deny-action@v1 with: command: check advisories @@ -18,7 +18,7 @@ jobs: name: cargo deny bans licenses sources runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: EmbarkStudios/cargo-deny-action@v1 with: command: check bans licenses sources diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 141c73fe..a3e419e9 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -10,7 +10,7 @@ jobs: env: RUSTDOCFLAGS: '--cfg=docsrs -Dwarnings' steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 with: rust-version: nightly diff --git a/.github/workflows/exhaustive.yml b/.github/workflows/exhaustive.yml index f6ca7ff2..97621676 100644 --- a/.github/workflows/exhaustive.yml +++ b/.github/workflows/exhaustive.yml @@ -16,7 +16,7 @@ jobs: - { toolchain: stable, target: x86_64-unknown-linux-gnu, os: ubuntu-latest } runs-on: ${{ matrix.platform.os }} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 with: rust-version: ${{ matrix.platform.toolchain }} @@ -31,7 +31,7 @@ jobs: name: cargo test --shallow-minimal-versions runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 with: rust-version: nightly @@ -64,7 +64,7 @@ jobs: env: RUSTFLAGS: -Dwarnings steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 - uses: actions-rs/cargo@v1 with: @@ -85,7 +85,7 @@ jobs: env: RUSTFLAGS: -Dwarnings steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 - uses: actions-rs/cargo@v1 with: diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 99af97fb..dcb31a78 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -8,7 +8,7 @@ jobs: name: cargo fmt --check runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 with: { components: rustfmt } - uses: actions-rs/cargo@v1 @@ -20,7 +20,7 @@ jobs: name: cargo clippy runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 with: { components: clippy } - uses: actions-rs/cargo@v1 diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index 3cba2477..a4ba6e41 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -8,7 +8,7 @@ jobs: name: cargo +nightly test runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 with: rust-version: nightly @@ -22,7 +22,7 @@ jobs: name: cargo +nightly fmt --check runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 with: rust-version: nightly @@ -37,7 +37,7 @@ jobs: name: cargo +nightly clippy runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: hecrj/setup-rust-action@v1 with: rust-version: nightly From 12d0f5f935fa56162b33b535116d49956494abf4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 31 Aug 2022 15:32:24 +0000 Subject: [PATCH 29/34] Bump ntest from 0.7.5 to 0.8.1 Bumps [ntest](https://github.com/becheran/ntest) from 0.7.5 to 0.8.1. - [Release notes](https://github.com/becheran/ntest/releases) - [Commits](https://github.com/becheran/ntest/commits) --- updated-dependencies: - dependency-name: ntest dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- Cargo.lock | 16 ++++++++-------- Cargo.toml | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 5c029f4d..500c2ad9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -384,9 +384,9 @@ dependencies = [ [[package]] name = "ntest" -version = "0.7.5" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c544e496c816f0a59645c0bb69097e453df203954ae2ed4b3ac4251fad69d44" +checksum = "e865500b46e35210765d62d549178c520badc018b2a71a827c29b305d680d1fb" dependencies = [ "ntest_proc_macro_helper", "ntest_test_cases", @@ -395,15 +395,15 @@ dependencies = [ [[package]] name = "ntest_proc_macro_helper" -version = "0.7.5" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f52e34b414605b77efc95c3f0ecef01df0c324bcc7f68d9a9cb7a7552777e52" +checksum = "a0e328d267a679d683b55222b3d06c2fb7358220857945bfc4e65a6b531e9994" [[package]] name = "ntest_test_cases" -version = "0.7.5" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a81eb400abc87063f829560bc5c5c835177703b83d1cd991960db0b2a00abe" +checksum = "6f7caf063242bb66721e74515dc01a915901063fa1f994bee7a2b9136f13370e" dependencies = [ "proc-macro2 1.0.36", "quote 1.0.15", @@ -412,9 +412,9 @@ dependencies = [ [[package]] name = "ntest_timeout" -version = "0.7.5" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b10db009e117aca57cbfb70ac332348f9a89d09ff7204497c283c0f7a0c96323" +checksum = "bca6eaadc7c104fb2eb0c6d14782b9e33775aaf5584c3bcb0f87c89e3e6d6c07" dependencies = [ "ntest_proc_macro_helper", "proc-macro-crate", diff --git a/Cargo.toml b/Cargo.toml index d36de299..a8fa07dc 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -57,7 +57,7 @@ proptest-derive = "0.3.0" rand = "0.8.5" futures = "0.3.5" futures-test = "0.3.5" -ntest = "0.7.5" +ntest = "0.8.1" bytes-05 = { package = "bytes", version = "0.5.0" } bytes-06 = { package = "bytes", version = "0.6.0" } bytes = "1.0.0" From 1700bcfd04c7960d4207b8183bfdd752f4b0ce9c Mon Sep 17 00:00:00 2001 From: Wesley Wiser Date: Thu, 22 Sep 2022 11:49:58 -0400 Subject: [PATCH 30/34] Box the `BrotliState` value because it is very large This reduces the size of `BrotliDecoder` from 2592 bytes to 8 bytes. Fixes #172 --- src/codec/brotli/decoder.rs | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/codec/brotli/decoder.rs b/src/codec/brotli/decoder.rs index 0eeab3f9..648f173d 100644 --- a/src/codec/brotli/decoder.rs +++ b/src/codec/brotli/decoder.rs @@ -7,17 +7,18 @@ use std::{ use brotli::{enc::StandardAlloc, BrotliDecompressStream, BrotliResult, BrotliState}; pub struct BrotliDecoder { - state: BrotliState, + // `BrotliState` is very large (over 2kb) which is why we're boxing it. + state: Box>, } impl BrotliDecoder { pub(crate) fn new() -> Self { Self { - state: BrotliState::new( + state: Box::new(BrotliState::new( StandardAlloc::default(), StandardAlloc::default(), StandardAlloc::default(), - ), + )), } } @@ -57,11 +58,11 @@ impl BrotliDecoder { impl Decode for BrotliDecoder { fn reinit(&mut self) -> Result<()> { - self.state = BrotliState::new( + self.state = Box::new(BrotliState::new( StandardAlloc::default(), StandardAlloc::default(), StandardAlloc::default(), - ); + )); Ok(()) } From 7118845518dc3f1c8c56d6526b1bb7036c9de1c4 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Sat, 8 Oct 2022 11:23:49 +0200 Subject: [PATCH 31/34] Fix endianness when reading the `extra` field of a gzip header MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit As specified in RFC1952 §2.1 multi-byte values are stored in little endian format. --- src/codec/gzip/header.rs | 2 +- tests/gzip.rs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/codec/gzip/header.rs b/src/codec/gzip/header.rs index 2132da08..8d82301e 100644 --- a/src/codec/gzip/header.rs +++ b/src/codec/gzip/header.rs @@ -85,7 +85,7 @@ impl Parser { data.copy_unwritten_from(input); if data.unwritten().is_empty() { - let len = u16::from_be_bytes(data.take().into_inner()); + let len = u16::from_le_bytes(data.take().into_inner()); self.state = State::Extra(vec![0; usize::from(len)].into()); } else { return Ok(None); diff --git a/tests/gzip.rs b/tests/gzip.rs index 1594986f..b17c7b34 100644 --- a/tests/gzip.rs +++ b/tests/gzip.rs @@ -109,6 +109,7 @@ fn compress_with_header(data: &[u8]) -> Vec { let mut gz = GzBuilder::new() .filename("hello_world.txt") .comment("test file, please delete") + .extra(vec![1, 2, 3, 4]) .write(&mut bytes, Compression::fast()); gz.write_all(data).unwrap(); From 886288e56158c9ce90dc8f1ef1aa106c56b99538 Mon Sep 17 00:00:00 2001 From: Wim Looman Date: Sat, 8 Oct 2022 11:29:12 +0200 Subject: [PATCH 32/34] Bump version to 0.3.15 --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 500c2ad9..526cda1a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -25,7 +25,7 @@ dependencies = [ [[package]] name = "async-compression" -version = "0.3.14" +version = "0.3.15" dependencies = [ "brotli", "bytes 0.5.6", diff --git a/Cargo.toml b/Cargo.toml index a8fa07dc..8e9b0823 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "async-compression" -version = "0.3.14" +version = "0.3.15" authors = ["Wim Looman ", "Allen Bui "] edition = "2018" license = "MIT OR Apache-2.0" From b39918dc21b2c4927fd96a025ecf0ce037a83b75 Mon Sep 17 00:00:00 2001 From: Rob Ede Date: Sat, 6 May 2023 15:14:56 +0100 Subject: [PATCH 33/34] chore: update locked vulnerable deps --- Cargo.lock | 235 ++++++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 205 insertions(+), 30 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 526cda1a..85f9c595 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -45,7 +45,7 @@ dependencies = [ "rand", "tokio 0.2.25", "tokio 0.3.7", - "tokio 1.15.0", + "tokio 1.24.2", "tokio-util 0.3.1", "tokio-util 0.4.0", "tokio-util 0.5.1", @@ -57,9 +57,9 @@ dependencies = [ [[package]] name = "autocfg" -version = "1.0.1" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdb031dd78e28731d87d56cc8ffef4a8f36ca26c38fe2de700543e627f8a464a" +checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bit-set" @@ -129,9 +129,9 @@ checksum = "c4872d67bab6358e59559027aa3b9157c53d9358c51423c17554809a8858e0f8" [[package]] name = "bzip2" -version = "0.4.3" +version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6afcd980b5f3a45017c57e57a2fcccbb351cc43a356ce117ef760ef8052b89b0" +checksum = "bdb116a6ef3f6c3698828873ad02c3014b3c85cadb88496095628e3ef1e347f8" dependencies = [ "bzip2-sys", "libc", @@ -172,6 +172,27 @@ dependencies = [ "cfg-if", ] +[[package]] +name = "errno" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4bcfec3a70f97c962c307b2d2c56e358cf1d00b558d74262b5f929ee8cc7e73a" +dependencies = [ + "errno-dragonfly", + "libc", + "windows-sys 0.48.0", +] + +[[package]] +name = "errno-dragonfly" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" +dependencies = [ + "cc", + "libc", +] + [[package]] name = "fastrand" version = "1.7.0" @@ -316,6 +337,12 @@ dependencies = [ "wasi", ] +[[package]] +name = "hermit-abi" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fed44880c466736ef9a5c5b5facefb5ed0785676d0c02d612db14e54f0d84286" + [[package]] name = "instant" version = "0.1.12" @@ -325,6 +352,17 @@ dependencies = [ "cfg-if", ] +[[package]] +name = "io-lifetimes" +version = "1.0.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c66c74d2ae7e79a5a8f7ac924adbe38ee42a859c6539ad869eb51f0b52dc220" +dependencies = [ + "hermit-abi", + "libc", + "windows-sys 0.48.0", +] + [[package]] name = "jobserver" version = "0.1.24" @@ -342,9 +380,15 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" [[package]] name = "libc" -version = "0.2.125" +version = "0.2.142" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a987beff54b60ffa6d51982e1aa1146bc42f19bd26be28b0586f252fccf5317" + +[[package]] +name = "linux-raw-sys" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5916d2ae698f6de9bfb891ad7a8d65c09d232dc58cc4ac433c7da3b2fd84bc2b" +checksum = "f051f77a7c8e6957c0696eac88f26b0117e54f52d3fc682ab19397a8812846a4" [[package]] name = "log" @@ -626,12 +670,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f497285884f3fcff424ffc933e56d7cbca511def0c9831a7f9b5f6153e3cc89b" [[package]] -name = "remove_dir_all" -version = "0.5.3" +name = "rustix" +version = "0.36.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3acd125665422973a33ac9d3dd2df85edad0f4ae9b00dafb1a05e43a9f5ef8e7" +checksum = "3a38f9520be93aba504e8ca974197f46158de5dcaa9fa04b57c57cd6a679d658" dependencies = [ - "winapi", + "bitflags", + "errno", + "io-lifetimes", + "libc", + "linux-raw-sys", + "windows-sys 0.45.0", ] [[package]] @@ -682,16 +731,15 @@ dependencies = [ [[package]] name = "tempfile" -version = "3.3.0" +version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cdb1ef4eaeeaddc8fbd371e5017057064af0911902ef36b39801f67cc6d79e4" +checksum = "af18f7ae1acd354b992402e9ec5864359d693cd8a79dcbef59f76891701c1e95" dependencies = [ "cfg-if", "fastrand", - "libc", "redox_syscall", - "remove_dir_all", - "winapi", + "rustix", + "windows-sys 0.42.0", ] [[package]] @@ -743,13 +791,15 @@ dependencies = [ [[package]] name = "tokio" -version = "1.15.0" +version = "1.24.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbbf1c778ec206785635ce8ad57fe52b3009ae9e0c9f574a728f3049d3e55838" +checksum = "597a12a59981d9e3c38d216785b0c37399f6e415e8d0712047620f189371b0bb" dependencies = [ + "autocfg", "bytes 1.1.0", "memchr", "pin-project-lite 0.2.8", + "windows-sys 0.42.0", ] [[package]] @@ -816,7 +866,7 @@ dependencies = [ "futures-sink", "log", "pin-project-lite 0.2.8", - "tokio 1.15.0", + "tokio 1.24.2", ] [[package]] @@ -856,26 +906,151 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fd6fbd9a79829dd1ad0cc20627bf1ed606756a7f77edff7b66b7064f9cb327c6" [[package]] -name = "winapi" -version = "0.3.9" +name = "windows-sys" +version = "0.42.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" +checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" dependencies = [ - "winapi-i686-pc-windows-gnu", - "winapi-x86_64-pc-windows-gnu", + "windows_aarch64_gnullvm 0.42.2", + "windows_aarch64_msvc 0.42.2", + "windows_i686_gnu 0.42.2", + "windows_i686_msvc 0.42.2", + "windows_x86_64_gnu 0.42.2", + "windows_x86_64_gnullvm 0.42.2", + "windows_x86_64_msvc 0.42.2", ] [[package]] -name = "winapi-i686-pc-windows-gnu" -version = "0.4.0" +name = "windows-sys" +version = "0.45.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" +checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" +dependencies = [ + "windows-targets 0.42.2", +] [[package]] -name = "winapi-x86_64-pc-windows-gnu" -version = "0.4.0" +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.0", +] + +[[package]] +name = "windows-targets" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071" +dependencies = [ + "windows_aarch64_gnullvm 0.42.2", + "windows_aarch64_msvc 0.42.2", + "windows_i686_gnu 0.42.2", + "windows_i686_msvc 0.42.2", + "windows_x86_64_gnu 0.42.2", + "windows_x86_64_gnullvm 0.42.2", + "windows_x86_64_msvc 0.42.2", +] + +[[package]] +name = "windows-targets" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b1eb6f0cd7c80c79759c929114ef071b87354ce476d9d94271031c0497adfd5" +dependencies = [ + "windows_aarch64_gnullvm 0.48.0", + "windows_aarch64_msvc 0.48.0", + "windows_i686_gnu 0.48.0", + "windows_i686_msvc 0.48.0", + "windows_x86_64_gnu 0.48.0", + "windows_x86_64_gnullvm 0.48.0", + "windows_x86_64_msvc 0.48.0", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "597a5118570b68bc08d8d59125332c54f1ba9d9adeedeef5b99b02ba2b0698f8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91ae572e1b79dba883e0d315474df7305d12f569b400fcf90581b06062f7e1bc" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e08e8864a60f06ef0d0ff4ba04124db8b0fb3be5776a5cd47641e942e58c4d43" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2ef27e0d7bdfcfc7b868b317c1d32c641a6fe4629c171b8928c7b08d98d7cf3" + +[[package]] +name = "windows_i686_gnu" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c61d927d8da41da96a81f029489353e68739737d3beca43145c8afec9a31a84f" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "622a1962a7db830d6fd0a69683c80a18fda201879f0f447f065a3b7467daa241" + +[[package]] +name = "windows_i686_msvc" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44d840b6ec649f480a41c8d80f9c65108b92d89345dd94027bfe06ac444d1060" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4542c6e364ce21bf45d69fdd2a8e455fa38d316158cfd43b3ac1c5b1b19f8e00" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8de912b8b8feb55c064867cf047dda097f92d51efad5b491dfb98f6bbb70cb36" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca2b8a661f7628cbd23440e50b05d705db3686f894fc9580820623656af974b1" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26d41b46a36d453748aedef1486d5c7a85db22e56aff34643984ea85514e94a3" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7896dbc1f41e08872e9d5e8f8baa8fdd2677f29468c4e156210174edc7f7b953" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9aec5da331524158c6d1a4ac0ab1541149c0b9505fde06423b02f5ef0106b9f0" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" +checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a" [[package]] name = "xz2" From 1cdf8bca5d31d4167e5d2ced057487511a465fb9 Mon Sep 17 00:00:00 2001 From: Rob Ede Date: Sat, 6 May 2023 14:40:34 +0100 Subject: [PATCH 34/34] ci: remove most actions-rs actions --- .github/workflows/base.yml | 7 ++---- .github/workflows/coverage.yml | 14 +++-------- .github/workflows/docs.yml | 8 ++---- .github/workflows/exhaustive.yml | 43 +++++++++++--------------------- .github/workflows/lint.yml | 14 +++-------- .github/workflows/nightly.yml | 28 ++++++--------------- 6 files changed, 34 insertions(+), 80 deletions(-) diff --git a/.github/workflows/base.yml b/.github/workflows/base.yml index b59d1309..b25d28c9 100644 --- a/.github/workflows/base.yml +++ b/.github/workflows/base.yml @@ -9,11 +9,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: hecrj/setup-rust-action@v1 - - uses: actions-rs/cargo@v1 - with: - command: test - args: --workspace --locked --all-features + - uses: actions-rust-lang/setup-rust-toolchain@v1 + - run: cargo --locked test --workspace --all-features on: push: diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index 365160d9..de31745d 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -9,16 +9,10 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: actions-rs/toolchain@v1 - with: - toolchain: stable - - uses: actions-rs/tarpaulin@v0.1 - with: - args: - --locked - --all-features - -- - --skip 'proptest::' + - uses: actions-rust-lang/setup-rust-toolchain@v1 + - uses: taiki-e/cache-cargo-install-action@v1 + with: { tool: cargo-tarpaulin } + - run: cargo --locked tarpaulin --all-features -- --skip 'proptest::' - uses: codecov/codecov-action@v3 on: diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index a3e419e9..a43f02d9 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -11,14 +11,10 @@ jobs: RUSTDOCFLAGS: '--cfg=docsrs -Dwarnings' steps: - uses: actions/checkout@v3 - - uses: hecrj/setup-rust-action@v1 + - uses: actions-rust-lang/setup-rust-toolchain@v1 with: - rust-version: nightly - - uses: actions-rs/cargo@v1 - with: - command: doc toolchain: nightly - args: --all-features --no-deps + - run: cargo doc --all-features --no-deps on: push: diff --git a/.github/workflows/exhaustive.yml b/.github/workflows/exhaustive.yml index 97621676..a82a563e 100644 --- a/.github/workflows/exhaustive.yml +++ b/.github/workflows/exhaustive.yml @@ -17,15 +17,11 @@ jobs: runs-on: ${{ matrix.platform.os }} steps: - uses: actions/checkout@v3 - - uses: hecrj/setup-rust-action@v1 - with: - rust-version: ${{ matrix.platform.toolchain }} - targets: ${{ matrix.platform.target }} - - uses: actions-rs/cargo@v1 + - uses: actions-rust-lang/setup-rust-toolchain@v1 with: toolchain: ${{ matrix.platform.toolchain }} - command: test - args: --all --locked --all-features + target: ${{ matrix.platform.target }} + - run: cargo --locked test --all --all-features min-versions: name: cargo test --shallow-minimal-versions @@ -53,10 +49,7 @@ jobs: - uses: hecrj/setup-rust-action@v1 with: rust-version: stable - - uses: actions-rs/cargo@v1 - with: - command: test - args: --workspace --locked --all-features + - run: cargo --locked test --workspace --all-features check-features: name: cargo hack check --feature-powerset @@ -65,15 +58,11 @@ jobs: RUSTFLAGS: -Dwarnings steps: - uses: actions/checkout@v3 - - uses: hecrj/setup-rust-action@v1 - - uses: actions-rs/cargo@v1 - with: - command: install - args: cargo-hack - - uses: actions-rs/cargo@v1 - with: - command: hack - args: check + - uses: actions-rust-lang/setup-rust-toolchain@v1 + - uses: taiki-e/cache-cargo-install-action@v1 + with: { tool: cargo-hack } + - run: + cargo hack check --workspace --feature-powerset --no-dev-deps @@ -86,15 +75,11 @@ jobs: RUSTFLAGS: -Dwarnings steps: - uses: actions/checkout@v3 - - uses: hecrj/setup-rust-action@v1 - - uses: actions-rs/cargo@v1 - with: - command: install - args: cargo-hack - - uses: actions-rs/cargo@v1 - with: - command: hack - args: check + - uses: actions-rust-lang/setup-rust-toolchain@v1 + - uses: taiki-e/cache-cargo-install-action@v1 + with: { tool: cargo-hack } + - run: + cargo hack check --workspace --feature-powerset --all-targets diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index dcb31a78..354bf438 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -9,24 +9,18 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: hecrj/setup-rust-action@v1 + - uses: actions-rust-lang/setup-rust-toolchain@v1 with: { components: rustfmt } - - uses: actions-rs/cargo@v1 - with: - command: fmt - args: --all -- --check + - run: cargo fmt --all -- --check clippy: name: cargo clippy runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: hecrj/setup-rust-action@v1 + - uses: actions-rust-lang/setup-rust-toolchain@v1 with: { components: clippy } - - uses: actions-rs/cargo@v1 - with: - command: clippy - args: --all --all-targets --all-features --locked -- -D warnings + - run: cargo --locked clippy --all --all-targets --all-features -- -D warnings on: push: diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index a4ba6e41..46eb6fb0 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -9,44 +9,32 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: hecrj/setup-rust-action@v1 - with: - rust-version: nightly - - uses: actions-rs/cargo@v1 + - uses: actions-rust-lang/setup-rust-toolchain@v1 with: toolchain: nightly - command: test - args: --all --locked --all-features + - run: cargo --locked test --all --all-features fmt: name: cargo +nightly fmt --check runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: hecrj/setup-rust-action@v1 - with: - rust-version: nightly - components: rustfmt - - uses: actions-rs/cargo@v1 + - uses: actions-rust-lang/setup-rust-toolchain@v1 with: toolchain: nightly - command: fmt - args: --all -- --check + components: rustfmt + - run: cargo fmt --all -- --check clippy: name: cargo +nightly clippy runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: hecrj/setup-rust-action@v1 - with: - rust-version: nightly - components: clippy - - uses: actions-rs/cargo@v1 + - uses: actions-rust-lang/setup-rust-toolchain@v1 with: toolchain: nightly - command: clippy - args: --all --all-targets --all-features --locked -- -D warnings + components: clippy + - run: cargo --locked clippy --all --all-targets --all-features -- -D warnings on: schedule: