From 57bb51af7cc1124ced9b3968d5bf9b081da05061 Mon Sep 17 00:00:00 2001 From: Andrzej Ressel Date: Tue, 3 Dec 2024 02:00:00 +0100 Subject: [PATCH] wasip2 --- Cargo.lock | 140 ++++++++----------------------- justfile | 11 +-- regenerate_providers/src/main.rs | 7 +- 3 files changed, 46 insertions(+), 112 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index a781b4fff..f7f8aa14f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -170,7 +170,7 @@ checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -181,7 +181,7 @@ checksum = "721cae7de5c34fbb2acd27e21e6d2cf7b886dce0c27388d46c4e6c47ea4318dd" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -307,7 +307,7 @@ dependencies = [ "proc-macro2", "quote", "rustversion", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -476,7 +476,7 @@ dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -712,7 +712,7 @@ dependencies = [ "proc-macro2", "quote", "strsim", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -723,7 +723,7 @@ checksum = "d336a2a514f6ccccaa3e09b02d41d35330c07ddf03a62165fcec10bb561c7806" dependencies = [ "darling_core", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1032,7 +1032,7 @@ checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1664,7 +1664,7 @@ dependencies = [ "cfg-if", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1761,7 +1761,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1863,7 +1863,7 @@ dependencies = [ "pest_meta", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1904,7 +1904,7 @@ checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1983,7 +1983,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "64d1ec885c64d0457d564db4ec299b2dae3f9c02808b8ad9c3a089c591b18033" dependencies = [ "proc-macro2", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -2022,7 +2022,7 @@ dependencies = [ "prost", "prost-types", "regex", - "syn 2.0.89", + "syn 2.0.90", "tempfile", ] @@ -2036,7 +2036,7 @@ dependencies = [ "itertools 0.13.0", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -2076,17 +2076,11 @@ version = "0.0.0-DEV" name = "pulumi_wasm" version = "0.0.0-DEV" dependencies = [ - "anyhow", - "bitflags", "log", "pulumi_wasm_common", "pulumi_wasm_core", "serde", "serde_json", - "tonic-build", - "uuid", - "wasmtime", - "wasmtime-wasi", "wit-bindgen-rt", ] @@ -2115,14 +2109,12 @@ version = "0.0.0-DEV" dependencies = [ "log", "pulumi_wasm_wit", - "uuid", ] [[package]] name = "pulumi_wasm_core" version = "0.0.0-DEV" dependencies = [ - "anyhow", "log", "mockall", "prost", @@ -2217,19 +2209,19 @@ dependencies = [ "assert_cmd", "convert_case", "handlebars", - "itertools 0.13.0", - "predicates", + "prettyplease", + "proc-macro2", "regex", "serde", "serde_json", "serde_yaml", + "syn 2.0.90", ] [[package]] name = "pulumi_wasm_proto" version = "0.0.0-DEV" dependencies = [ - "mockall", "prost", "prost-types", "tonic", @@ -2262,24 +2254,15 @@ dependencies = [ "anyhow", "async-trait", "clap", - "directories", "futures", "log", "log4rs", "prost", - "prost-types", "pulumi_wasm_proto", "pulumi_wasm_runner_component_creator", "pulumi_wasm_wit", - "regex", - "reqwest", - "serde", - "serde_json", "tokio", "tonic", - "tonic-web", - "uuid", - "wac-graph", "wasmtime", "wasmtime-wasi", ] @@ -2297,7 +2280,6 @@ dependencies = [ "reqwest", "tokio", "wac-graph", - "wasmprinter 0.221.0", "wit-component 0.221.0", "wit-parser 0.221.0", ] @@ -2307,8 +2289,6 @@ name = "pulumi_wasm_rust" version = "0.0.0-DEV" dependencies = [ "anyhow", - "bitflags", - "futures", "log", "once_cell", "prettyplease", @@ -2318,7 +2298,7 @@ dependencies = [ "quote", "serde", "serde_json", - "syn 2.0.89", + "syn 2.0.90", "uuid", ] @@ -2326,9 +2306,8 @@ dependencies = [ name = "pulumi_wasm_rust_macro" version = "0.0.0-DEV" dependencies = [ - "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -2675,7 +2654,7 @@ checksum = "ad1e866f866923f252f05c889987993144fb74e722403468a4ebd70c3cd756c0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -2836,9 +2815,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.89" +version = "2.0.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44d46482f1c1c87acd84dea20c1bf5ebff4c757009ed6bf19cfd36fb10e92c4e" +checksum = "919d3b74a5dd0ccd15aeb8f93e7006bd9e14c295087c9896a110f490752bcf31" dependencies = [ "proc-macro2", "quote", @@ -2948,7 +2927,7 @@ checksum = "a4558b58466b9ad7ca0f102865eccc95938dca1a74a856f2b57b6629050da261" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -3000,7 +2979,7 @@ checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -3123,27 +3102,7 @@ dependencies = [ "prost-build", "prost-types", "quote", - "syn 2.0.89", -] - -[[package]] -name = "tonic-web" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5299dd20801ad736dccb4a5ea0da7376e59cd98f213bf1c3d478cf53f4834b58" -dependencies = [ - "base64 0.22.1", - "bytes", - "http", - "http-body", - "http-body-util", - "pin-project", - "tokio-stream", - "tonic", - "tower-http", - "tower-layer", - "tower-service", - "tracing", + "syn 2.0.90", ] [[package]] @@ -3166,22 +3125,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "tower-http" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e9cd434a998747dd2c4276bc96ee2e0c7a2eadf3cae88e52be55a05fa9053f5" -dependencies = [ - "bitflags", - "bytes", - "http", - "http-body", - "http-body-util", - "pin-project-lite", - "tower-layer", - "tower-service", -] - [[package]] name = "tower-layer" version = "0.3.3" @@ -3213,7 +3156,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -3429,7 +3372,7 @@ dependencies = [ "once_cell", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "wasm-bindgen-shared", ] @@ -3463,7 +3406,7 @@ checksum = "afc340c74d9005395cf9dd098506f7f44e38f2b4a21c6aaacf9a105ea5e1e836" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "wasm-bindgen-backend", "wasm-bindgen-shared", ] @@ -3622,17 +3565,6 @@ dependencies = [ "wasmparser 0.219.1", ] -[[package]] -name = "wasmprinter" -version = "0.221.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f4234d0682f373b1878cefd5b3d99843312478ee4f603b2cea34cc2135f0a65" -dependencies = [ - "anyhow", - "termcolor", - "wasmparser 0.221.0", -] - [[package]] name = "wasmtime" version = "27.0.0" @@ -3728,7 +3660,7 @@ dependencies = [ "anyhow", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "wasmtime-component-util", "wasmtime-wit-bindgen", "wit-parser 0.219.1", @@ -3788,7 +3720,7 @@ dependencies = [ "target-lexicon", "wasm-encoder 0.219.1", "wasmparser 0.219.1", - "wasmprinter 0.219.1", + "wasmprinter", "wasmtime-component-util", ] @@ -3844,7 +3776,7 @@ checksum = "df09be00c38f49172ca9936998938476e3f2df782673a39ae2ef9fb0838341b6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -3973,7 +3905,7 @@ dependencies = [ "proc-macro2", "quote", "shellexpand", - "syn 2.0.89", + "syn 2.0.90", "witx", ] @@ -3985,7 +3917,7 @@ checksum = "9b8eb1a5783540696c59cefbfc9e52570c2d5e62bd47bdf0bdcef29231879db2" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "wiggle-generate", ] @@ -4283,7 +4215,7 @@ dependencies = [ "heck", "indexmap 2.4.0", "prettyplease", - "syn 2.0.89", + "syn 2.0.90", "wasm-metadata 0.220.0", "wit-bindgen-core", "wit-component 0.220.0", @@ -4299,7 +4231,7 @@ dependencies = [ "prettyplease", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "wit-bindgen-core", "wit-bindgen-rust", ] @@ -4427,7 +4359,7 @@ checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] diff --git a/justfile b/justfile index cdbbe5658..e9cb53f88 100644 --- a/justfile +++ b/justfile @@ -58,16 +58,17 @@ build-wasm-components-release: # DO NOT EDIT - BUILD-WASM-COMPONENTS - START build-wasm-providers: - cargo build --target={{TARGET_NAME}} -p pulumi_wasm_docker_provider - cargo build --target={{TARGET_NAME}} -p pulumi_wasm_random_provider - cargo build --target={{TARGET_NAME}} -p pulumi_wasm_cloudflare_provider + cargo build --target={{TARGET_NAME}} \ + -p pulumi_wasm_docker_provider \ + -p pulumi_wasm_random_provider \ + -p pulumi_wasm_cloudflare_provider \ build-wasm-providers-release: - cargo component build \ + cargo build --target={{TARGET_NAME}} \ -p pulumi_wasm_docker_provider \ -p pulumi_wasm_random_provider \ -p pulumi_wasm_cloudflare_provider \ - --timings --release + --release # DO NOT EDIT - BUILD-WASM-COMPONENTS - END check: diff --git a/regenerate_providers/src/main.rs b/regenerate_providers/src/main.rs index 4e1d5ebdb..b1ac17d84 100644 --- a/regenerate_providers/src/main.rs +++ b/regenerate_providers/src/main.rs @@ -89,22 +89,23 @@ fn replace_regenerate_providers(providers: &[Provider], content: &str) -> String fn replace_build_wasm_components(providers: &[Provider], content: &str) -> String { let mut replacement = String::new(); replacement.push_str("build-wasm-providers:\n"); + replacement.push_str(" cargo build --target={{TARGET_NAME}} \\\n"); for provider in providers { replacement.push_str(&format!( - " cargo build --target={{{{TARGET_NAME}}}} -p pulumi_wasm_{}_provider\n", + " -p pulumi_wasm_{}_provider \\\n", provider.name )); } replacement.push('\n'); replacement.push_str("build-wasm-providers-release:\n"); - replacement.push_str(" cargo component build \\\n"); + replacement.push_str(" cargo build --target={{TARGET_NAME}} \\\n"); for provider in providers { replacement.push_str(&format!( " -p pulumi_wasm_{}_provider \\\n", provider.name )); } - replacement.push_str(" --timings --release\n"); + replacement.push_str(" --release\n"); let start_marker = "# DO NOT EDIT - BUILD-WASM-COMPONENTS - START"; let end_marker = "# DO NOT EDIT - BUILD-WASM-COMPONENTS - END";