From 08202ba77ce9bbe3246e57080af34cff0c0f8d15 Mon Sep 17 00:00:00 2001 From: "Shane F. Carr" Date: Mon, 6 May 2024 13:52:20 -0700 Subject: [PATCH] Don't enable datagen networking feature when not needed (#4867) --- provider/blob/Cargo.toml | 4 ++-- provider/fs/Cargo.toml | 6 +++--- provider/fs/src/export/mod.rs | 5 +++-- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/provider/blob/Cargo.toml b/provider/blob/Cargo.toml index 3849e7ca0d2..90891233e34 100644 --- a/provider/blob/Cargo.toml +++ b/provider/blob/Cargo.toml @@ -30,8 +30,8 @@ zerotrie = { workspace = true, features = ["serde", "zerovec"] } log = { workspace = true, optional = true } [dev-dependencies] -icu_locid = { path = "../../components/locid", features = ["serde"] } -icu_datagen = { path = "../../provider/datagen", default-features = false, features = ["networking"] } +icu_locid = { path = "../../components/locid", default-features = false, features = ["serde"] } +icu_datagen = { path = "../../provider/datagen", default-features = false } twox-hash = { workspace = true } [target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies] diff --git a/provider/fs/Cargo.toml b/provider/fs/Cargo.toml index e9a53597f39..64b8bfc6a23 100644 --- a/provider/fs/Cargo.toml +++ b/provider/fs/Cargo.toml @@ -34,9 +34,9 @@ serde_json = { workspace = true, features = ["std"], optional = true } [dev-dependencies] icu_benchmark_macros = { path = "../../tools/benchmark/macros" } -icu_locid = { path = "../../components/locid", features = ["serde"] } -icu_provider = { path = "../../provider/core", features = ["deserialize_json", "deserialize_bincode_1", "deserialize_postcard_1", "datagen"] } -icu_datagen = { path = "../../provider/datagen", features = ["networking"] } +icu_locid = { path = "../../components/locid", default-features = false, features = ["serde"] } +icu_provider = { path = "../../provider/core", default-features = false, features = ["deserialize_json", "deserialize_bincode_1", "deserialize_postcard_1", "datagen"] } +icu_datagen = { path = "../../provider/datagen", default-features = false } writeable = { path = "../../utils/writeable" } [target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies] diff --git a/provider/fs/src/export/mod.rs b/provider/fs/src/export/mod.rs index 6ff11fb79da..f7ba46d971b 100644 --- a/provider/fs/src/export/mod.rs +++ b/provider/fs/src/export/mod.rs @@ -13,6 +13,7 @@ //! ``` //! use icu_datagen::prelude::*; //! use icu_provider_fs::export::*; +//! use icu_provider::hello_world::*; //! //! let demo_path = std::env::temp_dir().join("icu4x_json_demo"); //! # let _ = std::fs::remove_dir_all(&demo_path); @@ -26,9 +27,9 @@ //! //! // Export something //! DatagenDriver::new() -//! .with_keys([icu_provider::hello_world::HelloWorldV1Marker::KEY]) +//! .with_keys([HelloWorldV1Marker::KEY]) //! .with_all_locales() -//! .export(&DatagenProvider::new_latest_tested(), exporter) +//! .export(&HelloWorldProvider, exporter) //! .unwrap(); //! # //! # let _ = std::fs::remove_dir_all(&demo_path);