From 981ec5f215e350962ec9b76906c2e2cd378a126a Mon Sep 17 00:00:00 2001 From: Jeff Charles Date: Thu, 15 Aug 2024 17:25:41 -0400 Subject: [PATCH] Allow using with Wasmtime 23 --- Cargo.lock | 216 +++++++++++++---------- crates/deterministic-wasi-ctx/Cargo.toml | 8 +- 2 files changed, 123 insertions(+), 101 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index ec7ada1..d0a02e8 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -76,12 +76,6 @@ dependencies = [ "syn", ] -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - [[package]] name = "backtrace" version = "0.3.73" @@ -262,21 +256,32 @@ dependencies = [ [[package]] name = "cranelift-bforest" -version = "0.109.0" +version = "0.110.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b6b33d7e757a887989eb18b35712b2a67d96171ec3149d1bfb657b29b7b367c" +checksum = "305d51c180ebdc46ef61bc60c54ae6512db3bc9a05842a1f1e762e45977019ab" dependencies = [ "cranelift-entity", ] +[[package]] +name = "cranelift-bitset" +version = "0.110.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3247afacd9b13d620033f3190d9e49d1beefc1acb33d5604a249956c9c13709" +dependencies = [ + "serde", + "serde_derive", +] + [[package]] name = "cranelift-codegen" -version = "0.109.0" +version = "0.110.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9acf15cb22be42d07c3b57d7856329cb228b7315d385346149df2566ad5e4aa" +checksum = "bd7ca95e831c18d1356da783765c344207cbdffea91e13e47fa9327dbb2e0719" dependencies = [ "bumpalo", "cranelift-bforest", + "cranelift-bitset", "cranelift-codegen-meta", "cranelift-codegen-shared", "cranelift-control", @@ -293,43 +298,44 @@ dependencies = [ [[package]] name = "cranelift-codegen-meta" -version = "0.109.0" +version = "0.110.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e934d301392b73b3f8b0540391fb82465a0f179a3cee7c726482ac4727efcc97" +checksum = "450c105fa1e51bfba4e95a86e926504a867ad5639d63f31d43fe3b7ec1f1c9ef" dependencies = [ "cranelift-codegen-shared", ] [[package]] name = "cranelift-codegen-shared" -version = "0.109.0" +version = "0.110.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8afb2a2566b3d54b854dfb288b3b187f6d3d17d6f762c92898207eba302931da" +checksum = "5479117cd1266881479908d383086561cee37e49affbea9b1e6b594cc21cc220" [[package]] name = "cranelift-control" -version = "0.109.0" +version = "0.110.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0100f33b704cdacd01ad66ff41f8c5030d57cbff078e2a4e49ab1822591299fa" +checksum = "34378804f0abfdd22c068a741cfeed86938b92375b2a96fb0b42c878e0141bfb" dependencies = [ "arbitrary", ] [[package]] name = "cranelift-entity" -version = "0.109.0" +version = "0.110.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8cfdc315e5d18997093e040a8d234bea1ac1e118a716d3e30f40d449e78207b" +checksum = "a48cb0a194c9ba82fec35a1e492055388d89b2e3c03dee9dcf2488892be8004d" dependencies = [ + "cranelift-bitset", "serde", "serde_derive", ] [[package]] name = "cranelift-frontend" -version = "0.109.0" +version = "0.110.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f74b84f16af2e982b0c0c72233503d9d55cbfe3865dbe807ca28dc6642a28b5" +checksum = "8327afc6c1c05f4be62fefce5b439fa83521c65363a322e86ea32c85e7ceaf64" dependencies = [ "cranelift-codegen", "log", @@ -339,15 +345,15 @@ dependencies = [ [[package]] name = "cranelift-isle" -version = "0.109.0" +version = "0.110.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adf306d3dde705fb94bd48082f01d38c4ededc74293a4c007805f610bf08bc6e" +checksum = "56b08621c00321efcfa3eee6a3179adc009e21ea8d24ca7adc3c326184bc3f48" [[package]] name = "cranelift-native" -version = "0.109.0" +version = "0.110.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ea0ebdef7aff4a79bcbc8b6495f31315f16b3bf311152f472eaa8d679352581" +checksum = "d51180b147c8557c1196c77b098f04140c91962e135ea152cd2fcabf40cf365c" dependencies = [ "cranelift-codegen", "libc", @@ -356,9 +362,9 @@ dependencies = [ [[package]] name = "cranelift-wasm" -version = "0.109.0" +version = "0.110.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d549108a1942065cdbac3bb96c2952afa0e1b9a3beff4b08c4308ac72257576d" +checksum = "019e3dccb7f15e0bc14f0ddc034ec608a66df8e05c9e1e16f75a7716f8461799" dependencies = [ "cranelift-codegen", "cranelift-entity", @@ -425,7 +431,7 @@ dependencies = [ [[package]] name = "deterministic-wasi-ctx" -version = "0.1.22" +version = "0.1.23" dependencies = [ "anyhow", "async-trait", @@ -917,15 +923,6 @@ dependencies = [ "rustix", ] -[[package]] -name = "memoffset" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a" -dependencies = [ - "autocfg", -] - [[package]] name = "miniz_oxide" version = "0.7.4" @@ -1175,6 +1172,9 @@ name = "semver" version = "1.0.23" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" +dependencies = [ + "serde", +] [[package]] name = "serde" @@ -1306,6 +1306,15 @@ version = "0.12.14" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e1fc403891a21bcfb7c37834ba66a547a8f402146eba7265b5a6d88059c9ff2f" +[[package]] +name = "termcolor" +version = "1.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06794f8f6c5c898b3275aebefa6b8a1cb24cd2c6c79397ab15774837a0bc5755" +dependencies = [ + "winapi-util", +] + [[package]] name = "thiserror" version = "1.0.61" @@ -1499,9 +1508,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasi-common" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b86fd41e1e26ff6af9451c6a332a5ce5f5283ca51e87d875cdd9a05305598ee3" +checksum = "9c19d0b2b2f88ef39e8f5fd0e29e8b00d129e0824cc8c06d2caf9866a6a72b6b" dependencies = [ "anyhow", "bitflags", @@ -1579,27 +1588,27 @@ checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" [[package]] name = "wasm-encoder" -version = "0.209.1" +version = "0.212.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b4a05336882dae732ce6bd48b7e11fe597293cb72c13da4f35d7d5f8d53b2a7" +checksum = "501940df4418b8929eb6d52f1aade1fdd15a5b86c92453cb696e3c906bd3fc33" dependencies = [ "leb128", ] [[package]] name = "wasm-encoder" -version = "0.211.1" +version = "0.215.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e7d931a1120ef357f32b74547646b6fa68ea25e377772b72874b131a9ed70d4" +checksum = "4fb56df3e06b8e6b77e37d2969a50ba51281029a9aeb3855e76b7f49b6418847" dependencies = [ "leb128", ] [[package]] name = "wasmparser" -version = "0.209.1" +version = "0.212.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07035cc9a9b41e62d3bb3a3815a66ab87c993c06fe1cf6b2a3f2a18499d937db" +checksum = "8d28bc49ba1e5c5b61ffa7a2eace10820443c4b7d1c0b144109261d14570fdf8" dependencies = [ "ahash", "bitflags", @@ -1611,23 +1620,25 @@ dependencies = [ [[package]] name = "wasmprinter" -version = "0.209.1" +version = "0.212.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ceca8ae6eaa8c7c87b33c25c53bdf299f8c2a764aee1179402ff7652ef3a6859" +checksum = "dfac65326cc561112af88c3028f6dfdb140acff67ede33a8e86be2dc6b8956f7" dependencies = [ "anyhow", + "termcolor", "wasmparser", ] [[package]] name = "wasmtime" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "786d8b5e7a4d54917c5ebe555b9667337e5f93383f49bddaaeec2eba68093b45" +checksum = "07232e0b473af36112da7348f51e73fa8b11047a6cb546096da3812930b7c93a" dependencies = [ "addr2line 0.21.0", "anyhow", "async-trait", + "bitflags", "bumpalo", "cc", "cfg-if", @@ -1642,7 +1653,6 @@ dependencies = [ "log", "mach2", "memfd", - "memoffset", "object", "once_cell", "paste", @@ -1657,7 +1667,7 @@ dependencies = [ "smallvec", "sptr", "target-lexicon", - "wasm-encoder 0.209.1", + "wasm-encoder 0.212.0", "wasmparser", "wasmtime-asm-macros", "wasmtime-cache", @@ -1677,18 +1687,18 @@ dependencies = [ [[package]] name = "wasmtime-asm-macros" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d697d99c341d4a9ffb72f3af7a02124d233eeb59aee010f36d88e97cca553d5e" +checksum = "e5a9c42562d879c749288d9a26acc0d95d2ca069e30c2ec2efce84461c4d62b3" dependencies = [ "cfg-if", ] [[package]] name = "wasmtime-cache" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "916610f9ae9a6c22deb25bba2e6247ba9f00b093d30620875203b91328a1adfa" +checksum = "38d5d5aac98c8ae87cf5244495da7722e3fa022aa6f3f4fcd5e3d6e5699ce422" dependencies = [ "anyhow", "base64", @@ -1706,9 +1716,9 @@ dependencies = [ [[package]] name = "wasmtime-component-macro" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b29b462b068e73b5b27fae092a27f47e5937cabf6b26be2779c978698a52feca" +checksum = "c0c3f57c4bc96f9b4a6ff4d6cb6e837913eff32e98d09e2b6d79b5c4647b415b" dependencies = [ "anyhow", "proc-macro2", @@ -1721,15 +1731,15 @@ dependencies = [ [[package]] name = "wasmtime-component-util" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9d2912c53d9054984b380dfbd7579f9c3681b2a73b903a56bd71a1c4f175f1e" +checksum = "1da707969bc31a565da9b32d087eb2370c95c6f2087c5539a15f2e3b27e77203" [[package]] name = "wasmtime-cranelift" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3975deafea000457ba84355c7c0fce0372937204f77026510b7b454f28a3a65" +checksum = "62cb6135ec46994299be711b78b03acaa9480de3715f827d450f0c947a84977c" dependencies = [ "anyhow", "cfg-if", @@ -1751,12 +1761,13 @@ dependencies = [ [[package]] name = "wasmtime-environ" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f444e900e848b884d8a8a2949b6f5b92af642a3e663ff8fbe78731143a55be61" +checksum = "9bcaa3b42a0718e9123da7fb75e8e13fc95df7db2a7e32e2f2f4f0d3333b7d6f" dependencies = [ "anyhow", "cpp_demangle", + "cranelift-bitset", "cranelift-entity", "gimli 0.28.1", "indexmap", @@ -1764,10 +1775,11 @@ dependencies = [ "object", "postcard", "rustc-demangle", + "semver", "serde", "serde_derive", "target-lexicon", - "wasm-encoder 0.209.1", + "wasm-encoder 0.212.0", "wasmparser", "wasmprinter", "wasmtime-component-util", @@ -1776,9 +1788,9 @@ dependencies = [ [[package]] name = "wasmtime-fiber" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ded58eb2d1bf0dcd2182d0ccd7055c4b10b50d711514f1d73f61515d0fa829d" +checksum = "baf1c805515f4bc157f70f998038951009d21a19c1ef8c5fbb374a11b1d56672" dependencies = [ "anyhow", "cc", @@ -1791,9 +1803,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-debug" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bc54198c6720f098210a85efb3ba8c078d1de4d373cdb6778850a66ae088d11" +checksum = "118e141e52f3898a531a612985bd09a5e05a1d646cad2f30a3020b675c21cd49" dependencies = [ "object", "once_cell", @@ -1803,9 +1815,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-icache-coherence" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5afe2f0499542f9a4bcfa1b55bfdda803b6ade4e7c93c6b99e0f39dba44b0a91" +checksum = "2cfee42dac5148fc2664ab1f5cb8d7fa77a28d1a2cf1d9483abc2c3d751a58b9" dependencies = [ "anyhow", "cfg-if", @@ -1815,16 +1827,17 @@ dependencies = [ [[package]] name = "wasmtime-slab" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a7de1f2bec5bbb35d532e61c85c049dc84ae671df60492f90b954ecf21169e7" +checksum = "42eb8f6515708ec67974998c3e644101db4186308985f5ef7c2ef324ff33c948" [[package]] name = "wasmtime-types" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "412463e9000e14cf6856be48628d2213c20c153e29ffc22b036980c892ea6964" +checksum = "046873fb8fb3e9652f3fd76fe99c8c8129007695c3d73b2e307fdae40f6e324c" dependencies = [ + "anyhow", "cranelift-entity", "serde", "serde_derive", @@ -1834,9 +1847,9 @@ dependencies = [ [[package]] name = "wasmtime-versioned-export-macros" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de5a9bc4f44ceeb168e9e8e3be4e0b4beb9095b468479663a9e24c667e36826f" +checksum = "99c02af2e9dbeb427304d1a08787d70ed0dbfec1af2236616f84c9f1f03e7969" dependencies = [ "proc-macro2", "quote", @@ -1845,9 +1858,9 @@ dependencies = [ [[package]] name = "wasmtime-wasi" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8abb1301089ed8e0b4840f539cba316a73ac382090f1b25d22d8c8eed8df49c7" +checksum = "b2a1349f254d0b8f2ec8f996d0982f040abf22cd6ab19e3cf67afd033c552208" dependencies = [ "anyhow", "async-trait", @@ -1876,9 +1889,9 @@ dependencies = [ [[package]] name = "wasmtime-winch" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed4db238a0241df2d15f79ad17b3a37a27f2ea6cb885894d81b42ae107544466" +checksum = "b2ceddc47a49af10908a288fdfdc296ab3932062cab62a785e3705bbb3709c59" dependencies = [ "anyhow", "cranelift-codegen", @@ -1893,9 +1906,9 @@ dependencies = [ [[package]] name = "wasmtime-wit-bindgen" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70dc077306b38288262e5ba01d4b21532a6987416cdc0aedf04bb06c22a68fdc" +checksum = "75f528f8b8a2376a3dacaf497d960216dd466d324425361e1e00e26de0a7705c" dependencies = [ "anyhow", "heck", @@ -1914,31 +1927,31 @@ dependencies = [ [[package]] name = "wast" -version = "211.0.1" +version = "215.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b25506dd82d00da6b14a87436b3d52b1d264083fa79cdb72a0d1b04a8595ccaa" +checksum = "1ff1d00d893593249e60720be04a7c1f42f1c4dc3806a2869f4e66ab61eb54cb" dependencies = [ "bumpalo", "leb128", "memchr", "unicode-width", - "wasm-encoder 0.211.1", + "wasm-encoder 0.215.0", ] [[package]] name = "wat" -version = "1.211.1" +version = "1.215.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb716ca6c86eecac2d82541ffc39860118fc0af9309c4f2670637bea2e1bdd7d" +checksum = "670bf4d9c8cf76ae242d70ded47c546525b6dafaa6871f9bcb065344bf2b4e3d" dependencies = [ - "wast 211.0.1", + "wast 215.0.0", ] [[package]] name = "wiggle" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29830e5d01c182d24b94092c697aa7ab0ee97d22e78a2bf40ca91eae6ebca5c2" +checksum = "af4a61a764e5c4f0cb8c1796859d266e75828c244089e77c81c6158dd8c4fda4" dependencies = [ "anyhow", "async-trait", @@ -1951,9 +1964,9 @@ dependencies = [ [[package]] name = "wiggle-generate" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "557567f2793508760cd855f7659b7a0b9dc4dbc451f53f1415d6943a15311ade" +checksum = "f2d45f4c50cfcbc222fb5221142fa65aa834d0a54b77b5760be0ea0a1ccad52d" dependencies = [ "anyhow", "heck", @@ -1966,9 +1979,9 @@ dependencies = [ [[package]] name = "wiggle-macro" -version = "22.0.0" +version = "23.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc26129a8aea20b62c961d1b9ab4a3c3b56b10042ed85d004f8678af0f21ba6e" +checksum = "12e0fbccad12e5b406effb8676eb3713fdbe366975fb65d56f960ace6da118e4" dependencies = [ "proc-macro2", "quote", @@ -1992,6 +2005,15 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" +[[package]] +name = "winapi-util" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb" +dependencies = [ + "windows-sys 0.48.0", +] + [[package]] name = "winapi-x86_64-pc-windows-gnu" version = "0.4.0" @@ -2000,9 +2022,9 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "winch-codegen" -version = "0.20.0" +version = "0.21.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85c6915884e731b2db0d8cf08cb64474cb69221a161675fd3c135f91febc3daa" +checksum = "2a41b67a37ea74e83c38ef495cc213aba73385236b1deee883dc869e835003b9" dependencies = [ "anyhow", "cranelift-codegen", @@ -2184,9 +2206,9 @@ dependencies = [ [[package]] name = "wit-parser" -version = "0.209.1" +version = "0.212.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e79b9e3c0b6bb589dec46317e645851e0db2734c44e2be5e251b03ff4a51269" +checksum = "ceeb0424aa8679f3fcf2d6e3cfa381f3d6fa6179976a2c05a6249dd2bb426716" dependencies = [ "anyhow", "id-arena", diff --git a/crates/deterministic-wasi-ctx/Cargo.toml b/crates/deterministic-wasi-ctx/Cargo.toml index 11c3de5..463a362 100644 --- a/crates/deterministic-wasi-ctx/Cargo.toml +++ b/crates/deterministic-wasi-ctx/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "deterministic-wasi-ctx" -version = "0.1.22" +version = "0.1.23" edition = "2021" license = "Apache-2.0 WITH LLVM-exception" description = "A wasi-common WasiCtx implementation that is fully deterministic" @@ -12,11 +12,11 @@ categories = ["wasm"] anyhow = "1.0.56" async-trait = "0.1.53" cap-primitives = "3.0.0" -wasi-common = ">= 20.0.0, < 23.0.0" +wasi-common = ">= 20.0.0, < 24.0.0" rand_core = "0.6.3" rand_pcg = "0.3.1" [dev-dependencies] more-asserts = "0.3.1" -wasmtime = "22.0.0" -wasmtime-wasi = "22.0.0" +wasmtime = "23.0.2" +wasmtime-wasi = "23.0.2"