From 6e9a4f27a128574a42c9d0a82c069e90e2e0a85f Mon Sep 17 00:00:00 2001 From: Baojun Wang Date: Fri, 15 Nov 2024 16:52:23 -0800 Subject: [PATCH] Upgrade cargo_toml to v0.20 Summary: Cargo.toml `[profile]` debug section doesn't have to be integer any more, see [cargo doc](https://doc.rust-lang.org/cargo/reference/profiles.html#debug). This is needed for `arc autocargo` to work, when importing `rav1d` crate, see Cargo.toml [link](https://github.com/memorysafety/rav1d/blob/8e1a34eca2b92c9b76c0d2123a098d8f8a183024/Cargo.toml#L61), and P1680061395 for errors when running `arc autocargo`. Notice `arc autocargo` uses dotslash binaries, hence it may take sometime for this diff to take effect (see [link](https://www.internalfb.com/intern/msdk/bump/autocargo)). Unfortunately v0.20 has breaking changes, below is a summary of changes other than third-party rust: - Updated `cargo_from_buck` (actual code changes & tests). - Fixed linter test cases (toml_edit changes?). - Fixed buck_auto_mode testes. - Fixed smore/store/cold.rs unittests. Reviewed By: capickett Differential Revision: D66017293 fbshipit-source-id: cfb0f1edb42ec0d28d87d0ba46b7de6081547dd9 --- Cargo.lock | 39 ++++++++++++++++++++++++--------------- Cargo.toml | 2 +- 2 files changed, 25 insertions(+), 16 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f6f39d1e..1fa8d1b4 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -203,12 +203,12 @@ dependencies = [ [[package]] name = "cargo_toml" -version = "0.17.2" +version = "0.20.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a969e13a7589e9e3e4207e153bae624ade2b5622fb4684a4923b23ec3d57719" +checksum = "88da5a13c620b4ca0078845707ea9c3faf11edbc3ffd8497d11d686211cd1ac0" dependencies = [ "serde", - "toml 0.8.8", + "toml 0.8.19", ] [[package]] @@ -1027,7 +1027,7 @@ dependencies = [ "syn 2.0.85", "tempfile", "termcolor", - "toml 0.8.8", + "toml 0.8.19", "toml_edit 0.20.5", "unicode-ident", "url", @@ -1151,9 +1151,9 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "0.6.4" +version = "0.6.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12022b835073e5b11e90a14f86838ceb1c8fb0325b72416845c487ac0fa95e80" +checksum = "87607cb1398ed59d48732e575a4c28a7a8ebf2454b964fe3f224f2afc07909e1" dependencies = [ "serde", ] @@ -1349,21 +1349,21 @@ dependencies = [ [[package]] name = "toml" -version = "0.8.8" +version = "0.8.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a195ec8c9da26928f773888e0742ca3ca1040c6cd859c919c9f59c1954ab35" +checksum = "a1ed1f98e3fdc28d6d910e6737ae6ab1a93bf1985935a1193e68f93eeb68d24e" dependencies = [ "serde", "serde_spanned", "toml_datetime", - "toml_edit 0.21.0", + "toml_edit 0.22.20", ] [[package]] name = "toml_datetime" -version = "0.6.5" +version = "0.6.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" +checksum = "0dd7358ecb8fc2f8d014bf86f6f638ce72ba252a2c3a2572f2a795f1d23efb41" dependencies = [ "serde", ] @@ -1378,20 +1378,20 @@ dependencies = [ "serde", "serde_spanned", "toml_datetime", - "winnow", + "winnow 0.5.17", ] [[package]] name = "toml_edit" -version = "0.21.0" +version = "0.22.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d34d383cd00a163b4a5b85053df514d45bc330f6de7737edfe0a93311d1eaa03" +checksum = "583c44c02ad26b0c3f3066fe629275e50627026c51ac2e595cca4c230ce1ce1d" dependencies = [ "indexmap", "serde", "serde_spanned", "toml_datetime", - "winnow", + "winnow 0.6.18", ] [[package]] @@ -1728,3 +1728,12 @@ checksum = "a3b801d0e0a6726477cc207f60162da452f3a95adb368399bef20a946e06f65c" dependencies = [ "memchr", ] + +[[package]] +name = "winnow" +version = "0.6.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "68a9bda4691f099d435ad181000724da8e5899daa10713c2d432552b9ccd3a6f" +dependencies = [ + "memchr", +] diff --git a/Cargo.toml b/Cargo.toml index dd7b60b0..1abf5d37 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,7 +11,7 @@ license = "MIT" [dependencies] anyhow = "1.0.86" cached = "0.39.0" -cargo_toml = "0.17.2" +cargo_toml = "0.20.5" clap = { version = "4.5.20", features = ["derive", "env", "string", "unicode", "wrap_help"] } dunce = "1.0.2" env_logger = "0.10"