diff --git a/Cargo.lock b/Cargo.lock index 27244ca..771f1d0 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2,15 +2,6 @@ # It is not intended for manual editing. version = 3 -[[package]] -name = "addr2line" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" -dependencies = [ - "gimli 0.29.0", -] - [[package]] name = "addr2line" version = "0.24.1" @@ -137,7 +128,7 @@ version = "0.3.74" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8d82cb332cdfaed17ae235a638438ac4d4839913cc2af585c3c6746e8f8bee1a" dependencies = [ - "addr2line 0.24.1", + "addr2line", "cfg-if", "libc", "miniz_oxide", @@ -196,9 +187,9 @@ checksum = "428d9aa8fbc0670b7b8d6030a7fadd0f86151cae55e4dbbece15f3780a3dfaf3" [[package]] name = "cap-fs-ext" -version = "3.2.0" +version = "3.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb23061fc1c4ead4e45ca713080fe768e6234e959f5a5c399c39eb41aa34e56e" +checksum = "e16619ada836f12897a72011fe99b03f0025b87a8dbbea4f3c9f89b458a23bf3" dependencies = [ "cap-primitives", "cap-std", @@ -208,9 +199,9 @@ dependencies = [ [[package]] name = "cap-net-ext" -version = "3.2.0" +version = "3.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f83ae11f116bcbafc5327c6af250341db96b5930046732e1905f7dc65887e0e1" +checksum = "710b0eb776410a22c89a98f2f80b2187c2ac3a8206b99f3412332e63c9b09de0" dependencies = [ "cap-primitives", "cap-std", @@ -220,9 +211,9 @@ dependencies = [ [[package]] name = "cap-primitives" -version = "3.3.0" +version = "3.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff5bcbaf57897c8f14098cc9ad48a78052930a9948119eea01b80ca224070fa6" +checksum = "82fa6c3f9773feab88d844aa50035a33fb6e7e7426105d2f4bb7aadc42a5f89a" dependencies = [ "ambient-authority", "fs-set-times", @@ -237,9 +228,9 @@ dependencies = [ [[package]] name = "cap-rand" -version = "3.2.0" +version = "3.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbcb16a619d8b8211ed61f42bd290d2a1ac71277a69cf8417ec0996fa92f5211" +checksum = "53774d49369892b70184f8312e50c1b87edccb376691de4485b0ff554b27c36c" dependencies = [ "ambient-authority", "rand", @@ -247,9 +238,9 @@ dependencies = [ [[package]] name = "cap-std" -version = "3.3.0" +version = "3.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6cf1a22e6eab501e025a9953532b1e95efb8a18d6364bf8a4a7547b30c49186" +checksum = "7f71b70818556b4fe2a10c7c30baac3f5f45e973f49fc2673d7c75c39d0baf5b" dependencies = [ "cap-primitives", "io-extras", @@ -259,9 +250,9 @@ dependencies = [ [[package]] name = "cap-time-ext" -version = "3.2.0" +version = "3.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61142dc51e25b7acc970ca578ce2c3695eac22bbba46c1073f5f583e78957725" +checksum = "69dd48afa2363f746c93f961c211f6f099fb594a3446b8097bc5f79db51b6816" dependencies = [ "ambient-authority", "cap-primitives", @@ -341,7 +332,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3538270d33cc669650c4b093848450d380def10c331d38c768e34cac80576e6e" dependencies = [ "termcolor", - "unicode-width", + "unicode-width 0.1.14", ] [[package]] @@ -376,18 +367,18 @@ dependencies = [ [[package]] name = "cranelift-bforest" -version = "0.112.1" +version = "0.114.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6e376bd92bddd03dcfc443b14382611cae5d10012aa0b1628bbf18bb73f12f7" +checksum = "2ba4f80548f22dc9c43911907b5e322c5555544ee85f785115701e6a28c9abe1" dependencies = [ "cranelift-entity", ] [[package]] name = "cranelift-bitset" -version = "0.112.1" +version = "0.114.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "45ecbe07f25a8100e5077933516200e97808f1d7196b5a073edb85fa08fde32e" +checksum = "005884e3649c3e5ff2dc79e8a94b138f11569cc08a91244a292714d2a86e9156" dependencies = [ "serde", "serde_derive", @@ -395,9 +386,9 @@ dependencies = [ [[package]] name = "cranelift-codegen" -version = "0.112.1" +version = "0.114.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc60913f32c1de18538c28bef74b8c87cf16de7841a1b0956fcf01b23237853a" +checksum = "fe4036255ec33ce9a37495dfbcfc4e1118fd34e693eff9a1e106336b7cd16a9b" dependencies = [ "bumpalo", "cranelift-bforest", @@ -407,44 +398,45 @@ dependencies = [ "cranelift-control", "cranelift-entity", "cranelift-isle", - "gimli 0.29.0", + "gimli 0.31.0", "hashbrown 0.14.5", "log", "regalloc2", "rustc-hash", + "serde", "smallvec", "target-lexicon", ] [[package]] name = "cranelift-codegen-meta" -version = "0.112.1" +version = "0.114.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bae009e7822f47aa55e7dcef846ccf3aa4eb102ca6b4bcb8a44b36f3f49aa85c" +checksum = "f7ca74f4b68319da11d39e894437cb6e20ec7c2e11fbbda823c3bf207beedff7" dependencies = [ "cranelift-codegen-shared", ] [[package]] name = "cranelift-codegen-shared" -version = "0.112.1" +version = "0.114.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c78f01a852536c68e34444450f845ed6e0782a1f047f85397fe460b8fbce8f1" +checksum = "897e54f433a0269c4187871aa06d452214d5515d228d5bdc22219585e9eef895" [[package]] name = "cranelift-control" -version = "0.112.1" +version = "0.114.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a061b22e00a9e36b31f2660dfb05a9617b7775bd54b79754d3bb75a990dac06" +checksum = "29cb4018f5bf59fb53f515fa9d80e6f8c5ce19f198dc538984ebd23ecf8965ec" dependencies = [ "arbitrary", ] [[package]] name = "cranelift-entity" -version = "0.112.1" +version = "0.114.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95e2b261a3e74ae42f4e606906d5ffa44ee2684e8b1ae23bdf75d21908dc9233" +checksum = "305399fd781a2953ac78c1396f02ff53144f39c33eb7fc7789cf4e8936d13a96" dependencies = [ "cranelift-bitset", "serde", @@ -453,9 +445,9 @@ dependencies = [ [[package]] name = "cranelift-frontend" -version = "0.112.1" +version = "0.114.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe14abba0e6bab42aca0f9ce757f96880f9187e88bc6cb975ed6acd8a42f7770" +checksum = "9230b460a128d53653456137751d27baf567947a3ab8c0c4d6e31fd08036d81e" dependencies = [ "cranelift-codegen", "log", @@ -465,37 +457,21 @@ dependencies = [ [[package]] name = "cranelift-isle" -version = "0.112.1" +version = "0.114.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "311d91ae72b37d4262b51217baf8c9e01f1afd5148931468da1fdb7e9d011347" +checksum = "b961e24ae3ec9813a24a15ae64bbd2a42e4de4d79a7f3225a412e3b94e78d1c8" [[package]] name = "cranelift-native" -version = "0.112.1" +version = "0.114.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a3f84c75e578189ff7a716c24ad83740b553bf583f2510b323bfe4c1a74bb93" +checksum = "4d5bd76df6c9151188dfa428c863b33da5b34561b67f43c0cf3f24a794f9fa1f" dependencies = [ "cranelift-codegen", "libc", "target-lexicon", ] -[[package]] -name = "cranelift-wasm" -version = "0.112.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f56b7b2476c47b2091eee5a20bc54a80fbb29ca5313ae2bd0dea52621abcfca1" -dependencies = [ - "cranelift-codegen", - "cranelift-entity", - "cranelift-frontend", - "itertools", - "log", - "smallvec", - "wasmparser 0.217.0", - "wasmtime-types", -] - [[package]] name = "crc32fast" version = "1.4.2" @@ -892,21 +868,15 @@ dependencies = [ [[package]] name = "gimli" -version = "0.29.0" +version = "0.31.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" +checksum = "32085ea23f3234fc7846555e85283ba4de91e21016dc0455a16286d87a292d64" dependencies = [ "fallible-iterator 0.3.0", "indexmap 2.5.0", "stable_deref_trait", ] -[[package]] -name = "gimli" -version = "0.31.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32085ea23f3234fc7846555e85283ba4de91e21016dc0455a16286d87a292d64" - [[package]] name = "hashbrown" version = "0.12.3" @@ -1017,9 +987,9 @@ dependencies = [ [[package]] name = "io-extras" -version = "0.18.2" +version = "0.18.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9f046b9af244f13b3bd939f55d16830ac3a201e8a9ba9661bfcb03e2be72b9b" +checksum = "7d45fd7584f9b67ac37bc041212d06bfac0700b36456b05890d36a3b626260eb" dependencies = [ "io-lifetimes", "windows-sys 0.52.0", @@ -1104,9 +1074,9 @@ checksum = "884e2677b40cc8c339eaefcb701c32ef1fd2493d71118dc0ca4b6a736c93bd67" [[package]] name = "libc" -version = "0.2.158" +version = "0.2.164" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" +checksum = "433bfe06b8c75da9b2e3fbea6e5329ff87748f0b144ef75306e674c3f6f7c13f" [[package]] name = "libm" @@ -1303,6 +1273,17 @@ dependencies = [ "cc", ] +[[package]] +name = "pulley-interpreter" +version = "27.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a3b8d81cf799e20564931e9867ca32de545188c6ee4c2e0f6e41d32f0c7dc6fb" +dependencies = [ + "cranelift-bitset", + "log", + "sptr", +] + [[package]] name = "quote" version = "1.0.37" @@ -1409,9 +1390,9 @@ checksum = "583034fd73374156e66797ed8e5b0d5690409c9226b22d87cb7f19821c05d152" [[package]] name = "rustix" -version = "0.38.37" +version = "0.38.41" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8acb788b847c24f28525660c4d7758620a7210875711f79e7f663cc152726811" +checksum = "d7f649912bc1495e167a6edee79151c84b1bad49748cb4f1f1167f459f6224f6" dependencies = [ "bitflags", "errno", @@ -1844,6 +1825,12 @@ version = "0.1.14" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7dd6e30e90baa6f72411720665d41d89b9a3d039dc45b8faea1ddd07f617f6af" +[[package]] +name = "unicode-width" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fc81956842c57dac11422a97c3b8195a1ff727f06e85c84ed2e8aa277c9a0fd" + [[package]] name = "unicode-xid" version = "0.2.6" @@ -1942,12 +1929,12 @@ dependencies = [ "wasm-compose", "wasm-metadata", "wasm-opt", - "wasmparser 0.218.0", + "wasmparser 0.219.1", "wasmtime", "wasmtime-wasi", - "wasmtime-wasi-runtime-config", + "wasmtime-wasi-config", "wit-component", - "wit-parser", + "wit-parser 0.217.0", ] [[package]] @@ -2007,9 +1994,9 @@ checksum = "c62a0a307cb4a311d3a07867860911ca130c3494e8c2719593806c08bc5d0484" [[package]] name = "wasm-compose" -version = "0.218.0" +version = "0.219.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd2eda0f1862911e023fdae47c4d41d9995418e63fbb0649f6da16be5aeafdd8" +checksum = "1ab2f5b648bf974ca8206a163b7229b5683b3192ba49a532a06a3d7522413f5f" dependencies = [ "anyhow", "heck 0.4.1", @@ -2021,8 +2008,8 @@ dependencies = [ "serde_derive", "serde_yaml", "smallvec", - "wasm-encoder 0.218.0", - "wasmparser 0.218.0", + "wasm-encoder 0.219.1", + "wasmparser 0.219.1", "wat", ] @@ -2047,12 +2034,22 @@ dependencies = [ [[package]] name = "wasm-encoder" -version = "0.218.0" +version = "0.219.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22b896fa8ceb71091ace9bcb81e853f54043183a1c9667cf93422c40252ffa0a" +checksum = "29cbbd772edcb8e7d524a82ee8cef8dd046fc14033796a754c3ad246d019fa54" dependencies = [ "leb128", - "wasmparser 0.218.0", + "wasmparser 0.219.1", +] + +[[package]] +name = "wasm-encoder" +version = "0.220.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ebf48234b389415b226a4daef6562933d38c7b28a8b8f64c5c4130dad1561ab7" +dependencies = [ + "leb128", + "wasmparser 0.220.0", ] [[package]] @@ -2136,14 +2133,13 @@ dependencies = [ "hashbrown 0.14.5", "indexmap 2.5.0", "semver", - "serde", ] [[package]] name = "wasmparser" -version = "0.218.0" +version = "0.219.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b09e46c7fceceaa72b2dd1a8a137ea7fd8f93dfaa69806010a709918e496c5dc" +checksum = "5c771866898879073c53b565a6c7b49953795159836714ac56a5befb581227c5" dependencies = [ "ahash", "bitflags", @@ -2153,24 +2149,34 @@ dependencies = [ "serde", ] +[[package]] +name = "wasmparser" +version = "0.220.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e246c2772ce3ebc83f89a2d4487ac5794cad6c309b2071818a88c7db7c36d87b" +dependencies = [ + "bitflags", + "indexmap 2.5.0", +] + [[package]] name = "wasmprinter" -version = "0.217.0" +version = "0.219.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50dc568b3e0d47e8f96ea547c90790cfa783f0205160c40de894a427114185ce" +checksum = "228cdc1f30c27816da225d239ce4231f28941147d34713dee8f1fff7cb330e54" dependencies = [ "anyhow", "termcolor", - "wasmparser 0.217.0", + "wasmparser 0.219.1", ] [[package]] name = "wasmtime" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03601559991d459a228236a49135364eac85ac00dc07b65fb95ae61a957793af" +checksum = "5b79302e3e084713249cc5622e8608e7410afdeeea8c8026d04f491d1fab0b4b" dependencies = [ - "addr2line 0.22.0", + "addr2line", "anyhow", "async-trait", "bitflags", @@ -2179,7 +2185,7 @@ dependencies = [ "cfg-if", "encoding_rs", "fxprof-processed-profile", - "gimli 0.29.0", + "gimli 0.31.0", "hashbrown 0.14.5", "indexmap 2.5.0", "ittapi", @@ -2193,6 +2199,7 @@ dependencies = [ "paste", "postcard", "psm", + "pulley-interpreter", "rayon", "rustix", "semver", @@ -2202,8 +2209,8 @@ dependencies = [ "smallvec", "sptr", "target-lexicon", - "wasm-encoder 0.217.0", - "wasmparser 0.217.0", + "wasm-encoder 0.219.1", + "wasmparser 0.219.1", "wasmtime-asm-macros", "wasmtime-cache", "wasmtime-component-macro", @@ -2217,23 +2224,23 @@ dependencies = [ "wasmtime-versioned-export-macros", "wasmtime-winch", "wat", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "wasmtime-asm-macros" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e453b3bde07312874c0c6703e2de9281daab46646172c1b71fa59a97226f858e" +checksum = "fe53a24e7016a5222875d8ca3ad6024b464465985693c42098cd0bb710002c28" dependencies = [ "cfg-if", ] [[package]] name = "wasmtime-cache" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a35e1d7cce7b536cc71955e5898b099104a577d2583694b7b31a6f38c14c04a3" +checksum = "0677a7e76c24746b68e3657f7cc50c0ff122ee7e97bbda6e710c1b790ebc93cb" dependencies = [ "anyhow", "base64", @@ -2245,15 +2252,15 @@ dependencies = [ "serde_derive", "sha2", "toml", - "windows-sys 0.52.0", + "windows-sys 0.59.0", "zstd", ] [[package]] name = "wasmtime-component-macro" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4a6faeabbdbfd27e24e8d5204207ba9c247a13cf84181ea721b5f209f281fe01" +checksum = "e118acbd2bc09b32ad8606bc7cef793bf5019c1b107772e64dc6c76b5055d40b" dependencies = [ "anyhow", "proc-macro2", @@ -2261,20 +2268,20 @@ dependencies = [ "syn 2.0.77", "wasmtime-component-util", "wasmtime-wit-bindgen", - "wit-parser", + "wit-parser 0.219.1", ] [[package]] name = "wasmtime-component-util" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b1b24db4aa3dc7c0d3181d1833b4fe9ec0cd3f08780b746415c84c0a9ec9011" +checksum = "4a6db4f3ee18c699629eabb9c64e77efe5a93a5137f098db7cab295037ba41c2" [[package]] name = "wasmtime-cranelift" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c737bef9ea94aab874e29ac6a8688b89ceb43c7b51f047079c43387972c07ee3" +checksum = "8b87e6c78f562b50aff1afd87ff32a57e241424c846c1c8f3c5fd352d2d62906" dependencies = [ "anyhow", "cfg-if", @@ -2283,29 +2290,29 @@ dependencies = [ "cranelift-entity", "cranelift-frontend", "cranelift-native", - "cranelift-wasm", - "gimli 0.29.0", + "gimli 0.31.0", + "itertools", "log", "object", "smallvec", "target-lexicon", "thiserror", - "wasmparser 0.217.0", + "wasmparser 0.219.1", "wasmtime-environ", "wasmtime-versioned-export-macros", ] [[package]] name = "wasmtime-environ" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "817bfa9ea878ec37aa24f85fd6912844e8d87d321662824cf920d561b698cdfd" +checksum = "c25bfeaa16432d59a0706e2463d315ef4c9ebcfaf5605670b99d46373bdf9f27" dependencies = [ "anyhow", "cpp_demangle", "cranelift-bitset", "cranelift-entity", - "gimli 0.29.0", + "gimli 0.31.0", "indexmap 2.5.0", "log", "object", @@ -2314,19 +2321,19 @@ dependencies = [ "semver", "serde", "serde_derive", + "smallvec", "target-lexicon", - "wasm-encoder 0.217.0", - "wasmparser 0.217.0", + "wasm-encoder 0.219.1", + "wasmparser 0.219.1", "wasmprinter", "wasmtime-component-util", - "wasmtime-types", ] [[package]] name = "wasmtime-fiber" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5070971b479b4e4879dbae8a8e1efee738a36d047c5738acfedb38d6740b79d1" +checksum = "759ab0caa3821a6211743fe1eed448ab9df439e3af6c60dea15486c055611806" dependencies = [ "anyhow", "cc", @@ -2334,58 +2341,43 @@ dependencies = [ "rustix", "wasmtime-asm-macros", "wasmtime-versioned-export-macros", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "wasmtime-jit-debug" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26fd0000903068c13465b9c023f56f0664f433035cbbd8eae69aa7c755f97637" +checksum = "ab2a056056e9ac6916c2b8e4743408560300c1355e078c344211f13210d449b3" dependencies = [ "object", - "once_cell", "rustix", "wasmtime-versioned-export-macros", ] [[package]] name = "wasmtime-jit-icache-coherence" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48011232c0da424f89c3752a378d0b7f512fae321ea414a43e1e7a302a6a1f7e" +checksum = "91b218a92866f74f35162f5d03a4e0f62cd0e1cc624285b1014275e5d4575fad" dependencies = [ "anyhow", "cfg-if", "libc", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "wasmtime-slab" -version = "25.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9858a22e656ae8574631221b474b8bebf63f1367fcac3f179873833eabc2ced" - -[[package]] -name = "wasmtime-types" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d14b8a9206fe94485a03edb1654cd530dbd2a859a85a43502cb4e99653a568c" -dependencies = [ - "anyhow", - "cranelift-entity", - "serde", - "serde_derive", - "smallvec", - "wasmparser 0.217.0", -] +checksum = "4d5f8acf677ee6b3b8ba400dd9753ea4769e56a95c4b30b045ac6d2d54b2f8ea" [[package]] name = "wasmtime-versioned-export-macros" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9bb1f01efb8b542eadfda511e8ea1cc54309451aba97b69969e5b1a59cb7ded" +checksum = "df09be00c38f49172ca9936998938476e3f2df782673a39ae2ef9fb0838341b6" dependencies = [ "proc-macro2", "quote", @@ -2394,9 +2386,9 @@ dependencies = [ [[package]] name = "wasmtime-wasi" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2cc26a3923937186f5a4a4fa44d9dd1a7a389bbb06f8bac03cde2d52aad3ace8" +checksum = "ad5cf227161565057fc994edf14180341817372a218f1597db48a43946e5f875" dependencies = [ "anyhow", "async-trait", @@ -2411,7 +2403,6 @@ dependencies = [ "futures", "io-extras", "io-lifetimes", - "once_cell", "rustix", "system-interface", "thiserror", @@ -2420,14 +2411,14 @@ dependencies = [ "url", "wasmtime", "wiggle", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] -name = "wasmtime-wasi-runtime-config" -version = "25.0.1" +name = "wasmtime-wasi-config" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7963fe5405a594ca8cc730b0ac5da6b2a4a60f422f0debbb5ee8b69b267232d" +checksum = "d7c95f84a7b5c0fd0353c56ff9c7572244d157fe9894b6c4d4cf61b01b85c95c" dependencies = [ "anyhow", "wasmtime", @@ -2435,16 +2426,16 @@ dependencies = [ [[package]] name = "wasmtime-winch" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b238eeaf55652df0e63a6829d1ca9ef726d63517f56194faa0f6b9941f8d9151" +checksum = "89d6b5297bea14d8387c3974b2b011de628cc9b188f135cec752b74fd368964b" dependencies = [ "anyhow", "cranelift-codegen", - "gimli 0.29.0", + "gimli 0.31.0", "object", "target-lexicon", - "wasmparser 0.217.0", + "wasmparser 0.219.1", "wasmtime-cranelift", "wasmtime-environ", "winch-codegen", @@ -2452,14 +2443,14 @@ dependencies = [ [[package]] name = "wasmtime-wit-bindgen" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb1596caa67b31ac675fd3da61685c4260f8b10832021db42c85d227b7ba8133" +checksum = "bf3963c9c29df91564d8bd181eb00d0dbaeafa1b2a01e15952bb7391166b704e" dependencies = [ "anyhow", - "heck 0.4.1", + "heck 0.5.0", "indexmap 2.5.0", - "wit-parser", + "wit-parser 0.219.1", ] [[package]] @@ -2473,31 +2464,31 @@ dependencies = [ [[package]] name = "wast" -version = "218.0.0" +version = "220.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a53cd1f0fa505df97557e36a58bddb8296e2fcdcd089529545ebfdb18a1b9d7" +checksum = "4e708c8de08751fd66e70961a32bae9d71901f14a70871e181cb8461a3bb3165" dependencies = [ "bumpalo", "leb128", "memchr", - "unicode-width", - "wasm-encoder 0.218.0", + "unicode-width 0.2.0", + "wasm-encoder 0.220.0", ] [[package]] name = "wat" -version = "1.218.0" +version = "1.220.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f87f8e14e776762e07927c27c2054d2cf678aab9aae2d431a79b3e31e4dd391" +checksum = "de4f1d7d59614ba690541360102b995c4eb1b9ed373701d5102cc1a968b1c5a3" dependencies = [ - "wast 218.0.0", + "wast 220.0.0", ] [[package]] name = "wiggle" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e998c11dd3f293a8f657ce14e9c8fdc5cddd858f1e6448290d4ec04ca7ffe5b7" +checksum = "80e0f6ef83a263c0fa11957c363aeaa76dc84832484d0e119f22810d4d0e09a7" dependencies = [ "anyhow", "async-trait", @@ -2510,12 +2501,12 @@ dependencies = [ [[package]] name = "wiggle-generate" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0d8db385e5207c1ac431837868c8e48fc3f7e81f3a146793086d661875520ec" +checksum = "dd266b290a0fdace3af6a05c6ebbcc54de303a774448ecf5a98cd0bc12d89c52" dependencies = [ "anyhow", - "heck 0.4.1", + "heck 0.5.0", "proc-macro2", "quote", "shellexpand", @@ -2525,9 +2516,9 @@ dependencies = [ [[package]] name = "wiggle-macro" -version = "25.0.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2706ee9e7d1e106de80a3b3c6ec2f42920149e2def3e8060187c8e61f99bc0ef" +checksum = "9b8eb1a5783540696c59cefbfc9e52570c2d5e62bd47bdf0bdcef29231879db2" dependencies = [ "proc-macro2", "quote", @@ -2568,17 +2559,17 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "winch-codegen" -version = "0.23.1" +version = "27.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ac790aaeff15764481c731239a45346df3f0af966839ac1575f49989fdbb542" +checksum = "8b42b678c8651ec4900d7600037d235429fc985c31cbc33515885ec0d2a9e158" dependencies = [ "anyhow", "cranelift-codegen", - "gimli 0.29.0", + "gimli 0.31.0", "regalloc2", "smallvec", "target-lexicon", - "wasmparser 0.217.0", + "wasmparser 0.219.1", "wasmtime-cranelift", "wasmtime-environ", ] @@ -2711,7 +2702,7 @@ checksum = "fc9cfd3f1b4e29e9a90fe04157764f24ae396cfb8530dae5753de140e73f9e56" dependencies = [ "anyhow", "heck 0.5.0", - "wit-parser", + "wit-parser 0.217.0", ] [[package]] @@ -2770,7 +2761,7 @@ dependencies = [ "wasm-encoder 0.217.0", "wasm-metadata", "wasmparser 0.217.0", - "wit-parser", + "wit-parser 0.217.0", ] [[package]] @@ -2791,6 +2782,24 @@ dependencies = [ "wasmparser 0.217.0", ] +[[package]] +name = "wit-parser" +version = "0.219.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4a86f669283257e8e424b9a4fc3518e3ade0b95deb9fbc0f93a1876be3eda598" +dependencies = [ + "anyhow", + "id-arena", + "indexmap 2.5.0", + "log", + "semver", + "serde", + "serde_derive", + "serde_json", + "unicode-xid", + "wasmparser 0.219.1", +] + [[package]] name = "witx" version = "0.9.1" diff --git a/Cargo.toml b/Cargo.toml index b7b980c..42e438d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -32,7 +32,7 @@ clap = { version = "4", features = ["derive"] } serde = { version = "1", features = ["derive"] } toml = "0.8" walrus = "0.22.0" -wasm-compose = "0.218" +wasm-compose = "0.219" wasm-metadata = "0.217" wasm-opt = { version = "0.116.1", optional = true } wit-component = "0.217" @@ -46,10 +46,10 @@ anyhow = "1" cap-std = "3.3.0" heck = { version = "0.5" } tokio = { version = "1.40", features = ["macros"] } -wasmtime = { version = "25", features = ["component-model"] } -wasmtime-wasi = "25" -wasmtime-wasi-runtime-config = "25" -wasmparser = "0.218" +wasmtime = { version = "27", features = ["component-model"] } +wasmtime-wasi = { version = "27" } +wasmtime-wasi-config = { version = "27" } +wasmparser = "0.219.1" [workspace.dependencies] anyhow = "1" diff --git a/README.md b/README.md index 227ad99..71dc190 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ Supports all of the current WASI subsystems: - [Clocks](#clocks): Allow / Deny - [Environment](#env): Set environment variables, configure host environment variable permissions -- [Runtime Config](#runtime-config): Set runtime configuration, configure host property permissions +- [Config](#config): Set configuration, configure host property permissions - [Exit](#exit): Allow / Deny - [Filesystem](#filesystem): Mount a read-only filesystem, configure host filesystem preopen remappings or pass-through. - [HTTP](#http): Allow / Deny @@ -83,7 +83,7 @@ wasi-virt component.wasm -e CUSTOM=VAR --allow-env -o virt.wasm wasi-virt component.wasm -e CUSTOM=VAR --allow-env=SOME,ENV_VARS -o virt.wasm ``` -### Runtime Config +### Config _experimental_ diff --git a/lib/package.wasm b/lib/package.wasm index 377cf70..3f21f5d 100644 Binary files a/lib/package.wasm and b/lib/package.wasm differ diff --git a/lib/virtual_adapter.debug.wasm b/lib/virtual_adapter.debug.wasm index 40dfc5e..7109b22 100755 Binary files a/lib/virtual_adapter.debug.wasm and b/lib/virtual_adapter.debug.wasm differ diff --git a/lib/virtual_adapter.wasm b/lib/virtual_adapter.wasm index c37aad8..35711ef 100755 Binary files a/lib/virtual_adapter.wasm and b/lib/virtual_adapter.wasm differ diff --git a/rust-toolchain.toml b/rust-toolchain.toml index f8d4f98..f1d9e72 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,4 +1,4 @@ [toolchain] -channel = "nightly-2024-05-22" +channel = "nightly-2024-11-06" components = ["rust-src"] targets = ["wasm32-unknown-unknown"] diff --git a/src/bin/wasi-virt.rs b/src/bin/wasi-virt.rs index 2347280..17136fc 100644 --- a/src/bin/wasi-virt.rs +++ b/src/bin/wasi-virt.rs @@ -58,13 +58,13 @@ struct Args { #[arg(short, long, use_value_delimiter(true), value_name("ENV=VAR"), value_parser = parse_key_val::, help_heading = "Env")] env: Option>, - // RUNTIME CONFIG - /// Allow unrestricted access to host runtime configuration properties, or to a comma-separated list of property names. - #[arg(long, num_args(0..), use_value_delimiter(true), require_equals(true), value_name("PROPERTY_NAME"), help_heading = "Runtime Config (experimental)")] + // CONFIG + /// Allow unrestricted access to host configuration properties, or to a comma-separated list of property names. + #[arg(long, num_args(0..), use_value_delimiter(true), require_equals(true), value_name("PROPERTY_NAME"), help_heading = "Config (experimental)")] allow_config: Option>, - /// Set runtime config property overrides - #[arg(short, long, use_value_delimiter(true), value_name("NAME=VALUE"), value_parser = parse_key_val::, help_heading = "Runtime Config (experimental)")] + /// Set config property overrides + #[arg(short, long, use_value_delimiter(true), value_name("NAME=VALUE"), value_parser = parse_key_val::, help_heading = "Config (experimental)")] config: Option>, // FS @@ -185,7 +185,7 @@ fn main() -> Result<()> { } None => { if allow_all { - // TODO enable once wasi:config/runtime is stable + // TODO enable once wasi:config/store is stable // config.allow_all(); } } diff --git a/src/lib.rs b/src/lib.rs index 88d5649..fe97a22 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -86,7 +86,7 @@ impl WasiVirt { self.exit(true); self.random(true); self.env().allow_all(); - // TODO enable once wasi:config/runtime is stable + // TODO enable once wasi:config/store is stable // self.config().allow_all(); self.fs().allow_host_preopens(); self.stdio().allow(); @@ -99,7 +99,7 @@ impl WasiVirt { self.exit(false); self.random(false); self.env().deny_all(); - // TODO enable once wasi:config/runtime is stable + // TODO enable once wasi:config/store is stable // self.config().deny_all(); self.fs().deny_host_preopens(); self.stdio().ignore(); @@ -178,7 +178,7 @@ impl WasiVirt { if !matches("wasi:cli/environment") { self.env = None; } - if !matches("wasi:config/runtime") { + if !matches("wasi:config/store") { self.config = None; } if !matches("wasi:filesystem/") { diff --git a/src/virt_config.rs b/src/virt_config.rs index ca124a2..4b801ec 100644 --- a/src/virt_config.rs +++ b/src/virt_config.rs @@ -212,7 +212,7 @@ pub(crate) fn create_config_virt<'a>(module: &'a mut Module, config: &VirtConfig /// Functions that represent the configuration functionality provided by WASI CLI const WASI_CONFIG_FNS: [&str; 2] = ["get", "get-all"]; -/// Stub imported functions that implement the WASI runtime config functionality +/// Stub imported functions that implement the WASI config functionality /// /// This function throws an error if any imported functions do not exist pub(crate) fn stub_config_virt(module: &mut Module) -> Result<()> { @@ -220,7 +220,7 @@ pub(crate) fn stub_config_virt(module: &mut Module) -> Result<()> { module.replace_imported_func( module .imports - .get_func("wasi:config/runtime@0.2.0-draft", fn_name)?, + .get_func("wasi:config/store@0.2.0-draft", fn_name)?, |(body, _)| { body.unreachable(); }, @@ -230,16 +230,16 @@ pub(crate) fn stub_config_virt(module: &mut Module) -> Result<()> { Ok(()) } -/// Strip exported functions that implement the WASI runtime config functionality +/// Strip exported functions that implement the WASI config functionality pub(crate) fn strip_config_virt(module: &mut Module) -> Result<()> { stub_config_virt(module)?; for fn_name in WASI_CONFIG_FNS { let Ok(fid) = module .exports - .get_func(format!("wasi:config/runtime@0.2.0-draft#{fn_name}")) + .get_func(format!("wasi:config/store@0.2.0-draft#{fn_name}")) else { - bail!("Expected CLI function {fn_name}") + bail!("Expected Config function {fn_name}") }; module.replace_exported_func(fid, |(body, _)| { body.unreachable(); diff --git a/tests/components/get-config/src/lib.rs b/tests/components/get-config/src/lib.rs index 074979d..fc9c581 100644 --- a/tests/components/get-config/src/lib.rs +++ b/tests/components/get-config/src/lib.rs @@ -13,7 +13,7 @@ impl Guest for VirtTestComponent { unimplemented!(); } fn test_get_config() -> Vec<(String, String)> { - wasi::config::runtime::get_all().unwrap() + wasi::config::store::get_all().unwrap() } fn test_file_read(_path: String) -> String { unimplemented!(); diff --git a/tests/virt.rs b/tests/virt.rs index 35c8024..b9d7942 100644 --- a/tests/virt.rs +++ b/tests/virt.rs @@ -13,7 +13,7 @@ use wasmtime::{ Config, Engine, Store, WasmBacktraceDetails, }; use wasmtime_wasi::{DirPerms, FilePerms, WasiCtx, WasiCtxBuilder, WasiView}; -use wasmtime_wasi_runtime_config::{WasiRuntimeConfig, WasiRuntimeConfigVariables}; +use wasmtime_wasi_config::{WasiConfig, WasiConfigVariables}; use wit_component::{ComponentEncoder, DecodedWasm}; use wit_parser::WorldItem; @@ -220,8 +220,8 @@ async fn virt_test() -> Result<()> { builder.env(k, v); } } - let runtime_config = { - let mut config = WasiRuntimeConfigVariables::new(); + let wasi_config = { + let mut config = WasiConfigVariables::new(); if let Some(host_config) = &test.host_config { for (k, v) in host_config { config.insert(k, v); @@ -246,7 +246,7 @@ async fn virt_test() -> Result<()> { struct CommandCtx { table: ResourceTable, wasi: WasiCtx, - runtime_config: WasiRuntimeConfigVariables, + wasi_config: WasiConfigVariables, } impl WasiView for CommandCtx { fn table(&mut self) -> &mut ResourceTable { @@ -257,21 +257,21 @@ async fn virt_test() -> Result<()> { } } impl CommandCtx { - fn runtime_config(&mut self) -> &mut WasiRuntimeConfigVariables { - &mut self.runtime_config + fn wasi_config(&mut self) -> &mut WasiConfigVariables { + &mut self.wasi_config } } wasmtime_wasi::add_to_linker_async(&mut linker)?; - wasmtime_wasi_runtime_config::add_to_linker(&mut linker, |ctx: &mut CommandCtx| { - WasiRuntimeConfig::new(ctx.runtime_config()) + wasmtime_wasi_config::add_to_linker(&mut linker, |ctx: &mut CommandCtx| { + WasiConfig::new(ctx.wasi_config()) })?; let mut store = Store::new( &engine, CommandCtx { table, wasi, - runtime_config, + wasi_config, }, ); diff --git a/virtual-adapter/src/config.rs b/virtual-adapter/src/config.rs index a7d6324..be508a7 100644 --- a/virtual-adapter/src/config.rs +++ b/virtual-adapter/src/config.rs @@ -1,5 +1,5 @@ -use crate::exports::wasi::config::runtime::{ConfigError, Guest as Runtime}; -use crate::wasi::config::runtime; +use crate::exports::wasi::config::store::{Error, Guest as Store}; +use crate::wasi::config::store; use crate::VirtAdapter; #[repr(C)] @@ -47,8 +47,8 @@ fn read_data_str(offset: &mut isize) -> &'static str { unsafe { core::str::from_utf8_unchecked(str_data) } } -impl Runtime for VirtAdapter { - fn get(key: String) -> Result, ConfigError> { +impl Store for VirtAdapter { + fn get(key: String) -> Result, Error> { let mut data_offset: isize = 0; for _ in 0..unsafe { config.host_field_cnt } { let config_key = read_data_str(&mut data_offset); @@ -69,13 +69,13 @@ impl Runtime for VirtAdapter { let is_allow_list = unsafe { config.host_fallback_allow }; let in_list = allow_or_deny.binary_search(&key.as_ref()).is_ok(); if is_allow_list && in_list || !is_allow_list && !in_list { - return runtime::get(&key).map_err(config_err_map); + return store::get(&key).map_err(config_err_map); } } Ok(None) } - fn get_all() -> Result, ConfigError> { + fn get_all() -> Result, Error> { let mut configuration = Vec::new(); let mut data_offset: isize = 0; for _ in 0..unsafe { config.host_field_cnt } { @@ -93,7 +93,7 @@ impl Runtime for VirtAdapter { } let is_allow_list = unsafe { config.host_fallback_allow }; - for (key, value) in runtime::get_all().map_err(config_err_map)? { + for (key, value) in store::get_all().map_err(config_err_map)? { if configuration[0..override_len] .binary_search_by_key(&&key, |(s, _)| s) .is_ok() @@ -110,9 +110,9 @@ impl Runtime for VirtAdapter { } } -fn config_err_map(err: runtime::ConfigError) -> ConfigError { +fn config_err_map(err: store::Error) -> Error { match err { - runtime::ConfigError::Upstream(msg) => ConfigError::Upstream(msg), - runtime::ConfigError::Io(msg) => ConfigError::Io(msg), + store::Error::Upstream(msg) => Error::Upstream(msg), + store::Error::Io(msg) => Error::Io(msg), } } diff --git a/wit/deps/config/runtime_config.wit b/wit/deps/config/store.wit similarity index 60% rename from wit/deps/config/runtime_config.wit rename to wit/deps/config/store.wit index 29d53b1..794379a 100644 --- a/wit/deps/config/runtime_config.wit +++ b/wit/deps/config/store.wit @@ -1,6 +1,6 @@ -interface runtime { - /// An error type that encapsulates the different errors that can occur fetching config - variant config-error { +interface store { + /// An error type that encapsulates the different errors that can occur fetching configuration values. + variant error { /// This indicates an error from an "upstream" config source. /// As this could be almost _anything_ (such as Vault, Kubernetes ConfigMaps, KeyValue buckets, etc), /// the error message is a string. @@ -14,12 +14,17 @@ interface runtime { io(string), } - /// Gets a single opaque config value set at the given key if it exists + /// Gets a configuration value of type `string` associated with the `key`. + /// + /// The value is returned as an `option`. If the key is not found, + /// `Ok(none)` is returned. If an error occurs, an `Err(error)` is returned. get: func( /// A string key to fetch key: string - ) -> result, config-error>; + ) -> result, error>; - /// Gets a list of all set config data - get-all: func() -> result>, config-error>; + /// Gets a list of configuration key-value pairs of type `string`. + /// + /// If an error occurs, an `Err(error)` is returned. + get-all: func() -> result>, error>; } diff --git a/wit/deps/config/world.wit b/wit/deps/config/world.wit index 378c4a7..1dc56d1 100644 --- a/wit/deps/config/world.wit +++ b/wit/deps/config/world.wit @@ -1,6 +1,6 @@ package wasi:config@0.2.0-draft; world imports { - /// The runtime interface for config - import runtime; -} \ No newline at end of file + /// The interface for wasi:config/store + import store; +} diff --git a/wit/virt.wit b/wit/virt.wit index 332d366..aced4ff 100644 --- a/wit/virt.wit +++ b/wit/virt.wit @@ -43,8 +43,8 @@ world virtual-adapter { export wasi:sockets/tcp@0.2.1; import wasi:sockets/udp@0.2.1; export wasi:sockets/udp@0.2.1; - import wasi:config/runtime@0.2.0-draft; - export wasi:config/runtime@0.2.0-draft; + import wasi:config/store@0.2.0-draft; + export wasi:config/store@0.2.0-draft; } world virtual-base { @@ -163,8 +163,8 @@ world virtual-exit { } world virtual-config { - import wasi:config/runtime@0.2.0-draft; - export wasi:config/runtime@0.2.0-draft; + import wasi:config/store@0.2.0-draft; + export wasi:config/store@0.2.0-draft; } world virt-test { @@ -184,7 +184,7 @@ world virt-test { import wasi:io/poll@0.2.1; import wasi:io/streams@0.2.1; import wasi:cli/environment@0.2.1; - import wasi:config/runtime@0.2.0-draft; + import wasi:config/store@0.2.0-draft; import wasi:filesystem/preopens@0.2.1; import wasi:cli/exit@0.2.1; import wasi:cli/stdin@0.2.1;