From 2e388f37de69460b8e5919e9f99837aa233d0d6a Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 4 May 2026 01:59:04 +0000 Subject: [PATCH 1/2] chore(deps): update rust crates --- Cargo.toml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index c359e6a8..9e11f099 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -64,7 +64,7 @@ cow-utils = "0.1.3" cp_r = "0.5.2" crossterm = { version = "0.29.0", features = ["event-stream"] } csv-async = { version = "1.3.1", features = ["tokio"] } -ctor = "0.13" +ctor = "1.0" ctrlc = "3.5.2" derive_more = "2.0.1" diff-struct = "0.5.3" @@ -120,7 +120,7 @@ serde_norway = "0.9.42" sha2 = "0.11.0" shared_memory = "0.12.4" shell-escape = "0.1.5" -similar = "2.7.0" +similar = "3.0.0" smallvec = { version = "2.0.0-alpha.12", features = ["std"] } snapshot_test = { path = "crates/snapshot_test" } stackalloc = "1.2.1" @@ -133,11 +133,11 @@ test-log = { version = "0.2.18", features = ["trace"] } thiserror = "2" tokio = "1.48.0" tokio-util = "0.7.17" -toml = "0.9.5" +toml = "1.0.0" tracing = "0.1.43" tracing-error = "0.2.1" tracing-subscriber = { version = "0.3.19", features = ["env-filter", "serde"] } -ts-rs = { version = "11.1.0" } +ts-rs = { version = "12.0.0" } tui-term = "0.3.1" twox-hash = "2.1.1" uuid = "1.18.1" From 045c5520306eef6e1569698fd1038242ae7e6777 Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 5 May 2026 07:50:21 +0000 Subject: [PATCH 2/2] fix: adapt to breaking changes in major rust crate updates - ts-rs 12: TS trait methods now take a `&Config` parameter; pass `Config::default()` at call sites and update `TS` impls accordingly - ts-rs 12: HashMap keys are now optional in generated TS; update the checked-in `run-config.ts` snapshot to match --- Cargo.lock | 60 +++++++++++++++-------- crates/vite_path/src/relative.rs | 10 ++-- crates/vite_str/src/lib.rs | 10 ++-- crates/vite_task_graph/run-config.ts | 2 +- crates/vite_task_graph/src/config/user.rs | 4 +- 5 files changed, 52 insertions(+), 34 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 65143ebd..324f0a6a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -751,9 +751,9 @@ dependencies = [ [[package]] name = "ctor" -version = "0.13.1" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3429e8f8e3ce0ffe475c411850f70468c70d7a87d2ac3d15dd44703fb885aede" +checksum = "f7335955a5f85f95f3188623240e081e7b2059a8ad1bae68944b7cfdd718fb10" dependencies = [ "link-section", "linktime-proc-macro", @@ -3164,9 +3164,9 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "1.0.4" +version = "1.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8bbf91e5a4d6315eee45e704372590b30e260ee83af6639d64557f51b067776" +checksum = "6662b5879511e06e8999a8a235d848113e942c9124f211511b16466ee2995f26" dependencies = [ "serde_core", ] @@ -3304,9 +3304,12 @@ checksum = "e320a6c5ad31d271ad523dcf3ad13e2767ad8b1cb8f047f75a8aeaf8da139da2" [[package]] name = "similar" -version = "2.7.0" +version = "3.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbbb5d9659141646ae647b42fe094daf6c6192d1620870b449d9557f748b2daa" +checksum = "04d93e861ede2e497b47833469b8ec9d5c07fa4c78ce7a00f6eb7dd8168b4b3f" +dependencies = [ + "bstr", +] [[package]] name = "siphasher" @@ -3717,17 +3720,17 @@ dependencies = [ [[package]] name = "toml" -version = "0.9.12+spec-1.1.0" +version = "1.1.2+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf92845e79fc2e2def6a5d828f0801e29a2f8acc037becc5ab08595c7d5e9863" +checksum = "81f3d15e84cbcd896376e6730314d59fb5a87f31e4b038454184435cd57defee" dependencies = [ "indexmap", "serde_core", "serde_spanned", - "toml_datetime", + "toml_datetime 1.1.1+spec-1.1.0", "toml_parser", "toml_writer", - "winnow", + "winnow 1.0.2", ] [[package]] @@ -3739,6 +3742,15 @@ dependencies = [ "serde_core", ] +[[package]] +name = "toml_datetime" +version = "1.1.1+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3165f65f62e28e0115a00b2ebdd37eb6f3b641855f9d636d3cd4103767159ad7" +dependencies = [ + "serde_core", +] + [[package]] name = "toml_edit" version = "0.23.10+spec-1.0.0" @@ -3746,25 +3758,25 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "84c8b9f757e028cee9fa244aea147aab2a9ec09d5325a9b01e0a49730c2b5269" dependencies = [ "indexmap", - "toml_datetime", + "toml_datetime 0.7.5+spec-1.1.0", "toml_parser", - "winnow", + "winnow 0.7.14", ] [[package]] name = "toml_parser" -version = "1.0.7+spec-1.1.0" +version = "1.1.2+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "247eaa3197818b831697600aadf81514e577e0cba5eab10f7e064e78ae154df1" +checksum = "a2abe9b86193656635d2411dc43050282ca48aa31c2451210f4202550afb7526" dependencies = [ - "winnow", + "winnow 1.0.2", ] [[package]] name = "toml_writer" -version = "1.0.6+spec-1.1.0" +version = "1.1.1+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab16f14aed21ee8bfd8ec22513f7287cd4a91aa92e44edfe2c17ddd004e92607" +checksum = "756daf9b1013ebe47a8776667b466417e2d4c5679d441c26230efd9ef78692db" [[package]] name = "tracing" @@ -3840,9 +3852,9 @@ dependencies = [ [[package]] name = "ts-rs" -version = "11.1.0" +version = "12.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4994acea2522cd2b3b85c1d9529a55991e3ad5e25cdcd3de9d505972c4379424" +checksum = "756050066659291d47a554a9f558125db17428b073c5ffce1daf5dcb0f7231d8" dependencies = [ "thiserror 2.0.18", "ts-rs-macros", @@ -3850,9 +3862,9 @@ dependencies = [ [[package]] name = "ts-rs-macros" -version = "11.1.0" +version = "12.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee6ff59666c9cbaec3533964505d39154dc4e0a56151fdea30a09ed0301f62e2" +checksum = "38d90eea51bc7988ef9e674bf80a85ba6804739e535e9cab48e4bb34a8b652aa" dependencies = [ "proc-macro2", "quote", @@ -4702,6 +4714,12 @@ dependencies = [ "memchr", ] +[[package]] +name = "winnow" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ee1708bef14716a11bae175f579062d4554d95be2c6829f518df847b7b3fdd0" + [[package]] name = "winreg" version = "0.10.1" diff --git a/crates/vite_path/src/relative.rs b/crates/vite_path/src/relative.rs index f1eb9f0f..46aedcbf 100644 --- a/crates/vite_path/src/relative.rs +++ b/crates/vite_path/src/relative.rs @@ -310,23 +310,23 @@ mod ts_impl { type OptionInnerType = Self; type WithoutGenerics = Self; - fn name() -> String { + fn name(_cfg: &ts_rs::Config) -> String { "string".to_owned() } - fn inline() -> String { + fn inline(_cfg: &ts_rs::Config) -> String { "string".to_owned() } - fn inline_flattened() -> String { + fn inline_flattened(_cfg: &ts_rs::Config) -> String { panic!("RelativePathBuf cannot be flattened") } - fn decl() -> String { + fn decl(_cfg: &ts_rs::Config) -> String { panic!("RelativePathBuf is a primitive type") } - fn decl_concrete() -> String { + fn decl_concrete(_cfg: &ts_rs::Config) -> String { panic!("RelativePathBuf is a primitive type") } } diff --git a/crates/vite_str/src/lib.rs b/crates/vite_str/src/lib.rs index 6c0f20c0..2237ad10 100644 --- a/crates/vite_str/src/lib.rs +++ b/crates/vite_str/src/lib.rs @@ -187,23 +187,23 @@ mod ts_impl { type OptionInnerType = Self; type WithoutGenerics = Self; - fn name() -> String { + fn name(_cfg: &ts_rs::Config) -> String { "string".to_owned() } - fn inline() -> String { + fn inline(_cfg: &ts_rs::Config) -> String { "string".to_owned() } - fn inline_flattened() -> String { + fn inline_flattened(_cfg: &ts_rs::Config) -> String { panic!("Str cannot be flattened") } - fn decl() -> String { + fn decl(_cfg: &ts_rs::Config) -> String { panic!("Str is a primitive type") } - fn decl_concrete() -> String { + fn decl_concrete(_cfg: &ts_rs::Config) -> String { panic!("Str is a primitive type") } } diff --git a/crates/vite_task_graph/run-config.ts b/crates/vite_task_graph/run-config.ts index 9c7852a9..026664c3 100644 --- a/crates/vite_task_graph/run-config.ts +++ b/crates/vite_task_graph/run-config.ts @@ -91,7 +91,7 @@ cache?: UserGlobalCacheConfig, /** * Task definitions */ -tasks?: { [key in string]?: Task }, +tasks?: { [key in string]: Task }, /** * Whether to automatically run `preX`/`postX` package.json scripts as * lifecycle hooks when script `X` is executed. diff --git a/crates/vite_task_graph/src/config/user.rs b/crates/vite_task_graph/src/config/user.rs index 206f57cb..79255ad6 100644 --- a/crates/vite_task_graph/src/config/user.rs +++ b/crates/vite_task_graph/src/config/user.rs @@ -295,7 +295,7 @@ impl UserRunConfig { // Only collect declarations from types that are exportable // (i.e., have an output path - built-in types like HashMap don't) if T::output_path().is_some() { - self.decls.push(T::decl()); + self.decls.push(T::decl(&ts_rs::Config::default())); } // Recursively visit dependencies of T T::visit_dependencies(self); @@ -323,7 +323,7 @@ impl UserRunConfig { // Export the main type types.push_str("\n\nexport "); - types.push_str(&Self::decl()); + types.push_str(&Self::decl(&ts_rs::Config::default())); types }