From 26f4bef8f19705f2d4e3b2228284b6fc0e49c087 Mon Sep 17 00:00:00 2001 From: nicholaslyang Date: Fri, 7 Jun 2024 14:38:46 -0400 Subject: [PATCH] Vendoring update-informer --- Cargo.lock | 293 +++++++++++++++------------- Cargo.toml | 6 +- crates/turborepo-updater/Cargo.toml | 2 +- crates/update-informer | 1 + 4 files changed, 167 insertions(+), 135 deletions(-) create mode 160000 crates/update-informer diff --git a/Cargo.lock b/Cargo.lock index 82bfbf456a081..0476fcba577d9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -563,8 +563,8 @@ dependencies = [ "bytes", "futures-util", "http 0.2.11", - "http-body", - "hyper", + "http-body 0.4.5", + "hyper 0.14.28", "itoa", "matchit", "memchr", @@ -593,7 +593,7 @@ dependencies = [ "bytes", "futures-util", "http 0.2.11", - "http-body", + "http-body 0.4.5", "mime", "rustversion", "tower-layer", @@ -609,8 +609,8 @@ dependencies = [ "bytes", "futures-util", "http 0.2.11", - "http-body", - "hyper", + "http-body 0.4.5", + "hyper 0.14.28", "tokio", "tower-service", ] @@ -1306,7 +1306,7 @@ dependencies = [ "tracing", "url", "which", - "winreg", + "winreg 0.10.1", ] [[package]] @@ -3305,7 +3305,7 @@ dependencies = [ "hash32", "rustc_version 0.4.0", "serde", - "spin 0.9.8", + "spin", "stable_deref_trait", ] @@ -3412,6 +3412,29 @@ dependencies = [ "pin-project-lite", ] +[[package]] +name = "http-body" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" +dependencies = [ + "bytes", + "http 1.1.0", +] + +[[package]] +name = "http-body-util" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0475f8b2ac86659c21b64320d5d653f9efe42acd2a4e560073ec61a155a34f1d" +dependencies = [ + "bytes", + "futures-core", + "http 1.1.0", + "http-body 1.0.0", + "pin-project-lite", +] + [[package]] name = "httparse" version = "1.8.0" @@ -3437,7 +3460,7 @@ dependencies = [ "crossbeam-utils", "form_urlencoded", "futures-util", - "hyper", + "hyper 0.14.28", "isahc", "lazy_static", "levenshtein", @@ -3491,7 +3514,7 @@ dependencies = [ "futures-util", "h2", "http 0.2.11", - "http-body", + "http-body 0.4.5", "httparse", "httpdate", "itoa", @@ -3503,17 +3526,40 @@ dependencies = [ "want", ] +[[package]] +name = "hyper" +version = "1.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe575dd17d0862a9a33781c8c4696a55c320909004a67a00fb286ba8b1bc496d" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "http 1.1.0", + "http-body 1.0.0", + "httparse", + "itoa", + "pin-project-lite", + "smallvec", + "tokio", + "want", +] + [[package]] name = "hyper-rustls" -version = "0.23.2" +version = "0.26.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1788965e61b367cd03a62950836d5cd41560c3577d90e40e0819373194d1661c" +checksum = "a0bea761b46ae2b24eb4aef630d8d1c398157b6fc29e6350ecf090a0b70c952c" dependencies = [ - "http 0.2.11", - "hyper", - "rustls 0.20.9", + "futures-util", + "http 1.1.0", + "hyper 1.3.1", + "hyper-util", + "rustls", + "rustls-pki-types", "tokio", "tokio-rustls", + "tower-service", ] [[package]] @@ -3522,7 +3568,7 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bbb958482e8c7be4bc3cf272a766a2b0bf1a6755e7a6ae777f017a31d11b13b1" dependencies = [ - "hyper", + "hyper 0.14.28", "pin-project-lite", "tokio", "tokio-io-timeout", @@ -3530,15 +3576,18 @@ dependencies = [ [[package]] name = "hyper-tls" -version = "0.5.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" +checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" dependencies = [ "bytes", - "hyper", + "http-body-util", + "hyper 1.3.1", + "hyper-util", "native-tls", "tokio", "tokio-native-tls", + "tower-service", ] [[package]] @@ -3547,13 +3596,33 @@ version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "880b8b1c98a5ec2a505c7c90db6d3f6f1f480af5655d9c5b55facc9382a5a5b5" dependencies = [ - "hyper", + "hyper 0.14.28", "pin-project", "tokio", "tokio-tungstenite", "tungstenite 0.18.0", ] +[[package]] +name = "hyper-util" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b875924a60b96e5d7b9ae7b066540b1dd1cbd90d1828f54c92e02a283351c56" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "http 1.1.0", + "http-body 1.0.0", + "hyper 1.3.1", + "pin-project-lite", + "socket2 0.5.4", + "tokio", + "tower", + "tower-service", + "tracing", +] + [[package]] name = "iana-time-zone" version = "0.1.57" @@ -5728,7 +5797,7 @@ dependencies = [ "shared_library", "shell-words", "winapi", - "winreg", + "winreg 0.10.1", ] [[package]] @@ -6415,21 +6484,22 @@ checksum = "e3a8614ee435691de62bcffcf4a66d91b3594bf1428a5722e79103249a095690" [[package]] name = "reqwest" -version = "0.11.17" +version = "0.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13293b639a097af28fc8a90f22add145a9c954e49d77da06263d58cf44d5fb91" +checksum = "566cafdd92868e0939d3fb961bd0dc25fcfaaed179291093b3d43e6b3150ea10" dependencies = [ - "base64 0.21.4", + "base64 0.22.1", "bytes", - "encoding_rs", + "futures-channel", "futures-core", "futures-util", - "h2", - "http 0.2.11", - "http-body", - "hyper", + "http 1.1.0", + "http-body 1.0.0", + "http-body-util", + "hyper 1.3.1", "hyper-rustls", "hyper-tls", + "hyper-util", "ipnet", "js-sys", "log", @@ -6438,12 +6508,14 @@ dependencies = [ "once_cell", "percent-encoding", "pin-project-lite", - "rustls 0.20.9", + "rustls", "rustls-native-certs", "rustls-pemfile", + "rustls-pki-types", "serde", "serde_json", "serde_urlencoded", + "sync_wrapper", "tokio", "tokio-native-tls", "tokio-rustls", @@ -6454,8 +6526,8 @@ dependencies = [ "wasm-bindgen-futures", "wasm-streams", "web-sys", - "webpki-roots 0.22.6", - "winreg", + "webpki-roots", + "winreg 0.52.0", ] [[package]] @@ -6467,21 +6539,6 @@ dependencies = [ "bytemuck", ] -[[package]] -name = "ring" -version = "0.16.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3053cf52e236a3ed746dfc745aa9cacf1b791d846bdaf412f60a8d7d6e17c8fc" -dependencies = [ - "cc", - "libc", - "once_cell", - "spin 0.5.2", - "untrusted 0.7.1", - "web-sys", - "winapi", -] - [[package]] name = "ring" version = "0.17.7" @@ -6491,8 +6548,8 @@ dependencies = [ "cc", "getrandom", "libc", - "spin 0.9.8", - "untrusted 0.9.0", + "spin", + "untrusted", "windows-sys 0.48.0", ] @@ -6665,57 +6722,56 @@ dependencies = [ [[package]] name = "rustls" -version = "0.20.9" +version = "0.22.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b80e3dec595989ea8510028f30c408a4630db12c9cbb8de34203b89d6577e99" +checksum = "bf4ef73721ac7bcd79b2b315da7779d8fc09718c6b3d2d1b2d94850eb8c18432" dependencies = [ "log", - "ring 0.16.20", - "sct", - "webpki", -] - -[[package]] -name = "rustls" -version = "0.21.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9d5a6813c0759e4609cd494e8e725babae6a2ca7b62a5536a13daaec6fcb7ba" -dependencies = [ - "log", - "ring 0.17.7", + "ring", + "rustls-pki-types", "rustls-webpki", - "sct", + "subtle", + "zeroize", ] [[package]] name = "rustls-native-certs" -version = "0.6.3" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9aace74cb666635c918e9c12bc0d348266037aa8eb599b5cba565709a8dff00" +checksum = "8f1fb85efa936c42c6d5fc28d2629bb51e4b2f4b8a5211e297d599cc5a093792" dependencies = [ "openssl-probe", "rustls-pemfile", + "rustls-pki-types", "schannel", "security-framework", ] [[package]] name = "rustls-pemfile" -version = "1.0.2" +version = "2.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d194b56d58803a43635bdc398cd17e383d6f71f9182b9a192c127ca42494a59b" +checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" dependencies = [ - "base64 0.21.4", + "base64 0.22.1", + "rustls-pki-types", ] +[[package]] +name = "rustls-pki-types" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" + [[package]] name = "rustls-webpki" -version = "0.101.7" +version = "0.102.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b6275d1ee7a1cd780b64aca7726599a1dbc893b1e64144529e55c3c2f745765" +checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" dependencies = [ - "ring 0.17.7", - "untrusted 0.9.0", + "ring", + "rustls-pki-types", + "untrusted", ] [[package]] @@ -6809,16 +6865,6 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" -[[package]] -name = "sct" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d53dcdb7c9f8158937a7981b48accfd39a43af418591a5d008c7b22b5e1b7ca4" -dependencies = [ - "ring 0.16.20", - "untrusted 0.7.1", -] - [[package]] name = "seahash" version = "4.1.0" @@ -7384,12 +7430,6 @@ dependencies = [ "url", ] -[[package]] -name = "spin" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" - [[package]] name = "spin" version = "0.9.8" @@ -9580,13 +9620,13 @@ dependencies = [ [[package]] name = "tokio-rustls" -version = "0.23.4" +version = "0.25.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c43ee83903113e03984cb9e5cebe6c04a5116269e900e3ddba8f068a62adda59" +checksum = "775e0c0f0adb3a2f22a00c4745d728b479985fc15ee7ca6a2608388c5569860f" dependencies = [ - "rustls 0.20.9", + "rustls", + "rustls-pki-types", "tokio", - "webpki", ] [[package]] @@ -9720,8 +9760,8 @@ dependencies = [ "futures-util", "h2", "http 0.2.11", - "http-body", - "hyper", + "http-body 0.4.5", + "hyper 0.14.28", "hyper-timeout", "percent-encoding", "pin-project", @@ -9750,8 +9790,8 @@ dependencies = [ "bytes", "h2", "http 0.2.11", - "http-body", - "hyper", + "http-body 0.4.5", + "hyper 0.14.28", "hyper-timeout", "percent-encoding", "pin-project", @@ -10065,7 +10105,7 @@ dependencies = [ [[package]] name = "turbo" -version = "2.0.2-canary.1" +version = "2.0.4-canary.2" dependencies = [ "anyhow", "assert_cmd", @@ -10608,7 +10648,7 @@ dependencies = [ "async-compression", "auto-hash-map", "futures", - "hyper", + "hyper 0.14.28", "hyper-tungstenite", "indexmap 1.9.3", "mime", @@ -11672,12 +11712,6 @@ version = "0.2.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1865806a559042e51ab5414598446a5871b561d21b6764f2eabb0dd481d880a6" -[[package]] -name = "untrusted" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4a" - [[package]] name = "untrusted" version = "0.9.0" @@ -11687,8 +11721,6 @@ checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" [[package]] name = "update-informer" version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f8811797a24ff123db3c6e1087aa42551d03d772b3724be421ad063da1f5f3f" dependencies = [ "directories", "reqwest", @@ -11700,21 +11732,22 @@ dependencies = [ [[package]] name = "ureq" -version = "2.9.1" +version = "2.9.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8cdd25c339e200129fe4de81451814e5228c9b771d57378817d6117cc2b3f97" +checksum = "d11a831e3c0b56e438a28308e7c810799e3c118417f342d30ecec080105395cd" dependencies = [ - "base64 0.21.4", + "base64 0.22.1", "flate2", "log", "native-tls", "once_cell", - "rustls 0.21.10", + "rustls", + "rustls-pki-types", "rustls-webpki", "serde", "serde_json", "url", - "webpki-roots 0.25.3", + "webpki-roots", ] [[package]] @@ -12139,9 +12172,9 @@ dependencies = [ [[package]] name = "wasm-streams" -version = "0.2.3" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bbae3363c08332cadccd13b67db371814cd214c2524020932f0804b8cf7c078" +checksum = "b65dc4c90b63b118468cf747d8bf3566c1913ef60be765b5730ead9e0a3ba129" dependencies = [ "futures-util", "js-sys", @@ -12523,31 +12556,15 @@ dependencies = [ "wasmer-toml", ] -[[package]] -name = "webpki" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f095d78192e208183081cc07bc5515ef55216397af48b873e5edcd72637fa1bd" -dependencies = [ - "ring 0.16.20", - "untrusted 0.7.1", -] - [[package]] name = "webpki-roots" -version = "0.22.6" +version = "0.26.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6c71e40d7d2c34a5106301fb632274ca37242cd0c9d3e64dbece371a40a2d87" +checksum = "3c452ad30530b54a4d8e71952716a212b08efd0f3562baa66c29a618b07da7c3" dependencies = [ - "webpki", + "rustls-pki-types", ] -[[package]] -name = "webpki-roots" -version = "0.25.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1778a42e8b3b90bff8d0f5032bf22250792889a5cdc752aa0020c84abe3aaf10" - [[package]] name = "weezl" version = "0.1.8" @@ -12915,6 +12932,16 @@ dependencies = [ "winapi", ] +[[package]] +name = "winreg" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" +dependencies = [ + "cfg-if", + "windows-sys 0.48.0", +] + [[package]] name = "wio" version = "0.2.2" diff --git a/Cargo.toml b/Cargo.toml index fc1ab25f5cbe6..ada2370c3446b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,6 +9,7 @@ members = [ "crates/turbo-prehash", "crates/turbopack*", "crates/turborepo*", + "crates/update-informer", "packages/turbo-repository/rust", "xtask", ] @@ -79,6 +80,7 @@ turbopack-wasi = [ # Config for 'cargo dist' [workspace.metadata.dist] dist = false +precise-builds = true # The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.15.1" # CI backends to support @@ -220,12 +222,13 @@ wax = { path = "crates/turborepo-wax" } turborepo-vercel-api = { path = "crates/turborepo-vercel-api" } turborepo-vercel-api-mock = { path = "crates/turborepo-vercel-api-mock" } turborepo-vt100 = { path = "crates/turborepo-vt100" } +update-informer = { path = "crates/update-informer" } # Be careful when selecting tls backend, including change default tls backend. # If you changed, must verify with ALL build targets with next-swc to ensure # it works. next-swc have various platforms, some doesn't support native (using openssl-sys) # and some aren't buildable with rustls. -reqwest = { version = "=0.11.17", default-features = false } +reqwest = { version = "0.12.4", default-features = false } chromiumoxide = { version = "0.5.0", features = [ "tokio-runtime", @@ -335,6 +338,7 @@ webbrowser = "0.8.7" which = "4.4.0" unicode-segmentation = "1.10.1" + [patch.crates-io] # TODO: Use upstream when https://github.com/servo/pathfinder/pull/566 lands pathfinder_simd = { git = "https://github.com/vercel/pathfinder", branch = "rm-stdarch_arm_crc32" } diff --git a/crates/turborepo-updater/Cargo.toml b/crates/turborepo-updater/Cargo.toml index 40c7cd268d2c4..8c316c5ed4400 100644 --- a/crates/turborepo-updater/Cargo.toml +++ b/crates/turborepo-updater/Cargo.toml @@ -22,6 +22,6 @@ reqwest = { workspace = true, features = ["json", "blocking"] } semver = { workspace = true } serde = { workspace = true, features = ["derive"] } thiserror = { workspace = true } -update-informer = { version = "1.1", default-features = false, features = [ +update-informer = { workspace = true, default-features = false, features = [ "reqwest", ] } diff --git a/crates/update-informer b/crates/update-informer new file mode 160000 index 0000000000000..de93b17bfcc25 --- /dev/null +++ b/crates/update-informer @@ -0,0 +1 @@ +Subproject commit de93b17bfcc2505e26a71959d888d44c81350baa