From 28647c25cc93d6b161c11bbaac8401b8b12e6271 Mon Sep 17 00:00:00 2001 From: markfisher Date: Mon, 17 Nov 2025 16:29:50 -0500 Subject: [PATCH 1/2] update wasi versions Signed-off-by: markfisher --- components/Cargo.lock | 248 +++++------------- components/Cargo.toml | 2 +- components/build.sh | 2 +- components/calculator/calculator.wat | 16 +- components/calculator/componentize.sh | 2 +- components/counter/Cargo.toml | 2 +- components/flights/Cargo.toml | 2 +- components/greeter/Cargo.toml | 2 +- components/hotels/Cargo.toml | 2 +- components/incrementor/Cargo.toml | 2 +- components/intercepting-greeter/Cargo.toml | 2 +- components/publish.sh | 2 +- components/rest-client/Cargo.toml | 2 +- components/valkey-publisher/Cargo.toml | 2 +- components/wit/calculator.wit | 8 +- components/wit/counter.wit | 2 +- .../package.wit | 8 +- .../wit/deps/wasi-clocks-0.2.3/package.wit | 29 -- .../wit/deps/wasi-clocks-0.2.8/package.wit | 162 ++++++++++++ .../package.wit | 2 +- .../package.wit | 62 +++-- .../package.wit | 2 +- .../deps/wasi-logging-0.1.0-draft/package.wit | 36 +++ .../package.wit | 2 +- components/wit/flights.wit | 2 +- components/wit/greeter.wit | 2 +- components/wit/hotels.wit | 2 +- components/wit/incrementor.wit | 2 +- components/wit/intercepting-greeter.wit | 2 +- .../wit/overrides/wasi-config/store.wit | 30 --- .../wit/overrides/wasi-config/world.wit | 6 - components/wit/package.wit | 2 +- components/wit/publisher.wit | 2 +- components/wit/rest-client.wit | 2 +- components/wkg.lock | 33 ++- components/wkg.toml | 3 +- 36 files changed, 377 insertions(+), 312 deletions(-) rename components/wit/deps/{wasi-cli-0.2.3 => wasi-cli-0.2.8}/package.wit (53%) delete mode 100644 components/wit/deps/wasi-clocks-0.2.3/package.wit create mode 100644 components/wit/deps/wasi-clocks-0.2.8/package.wit rename components/wit/deps/{wasi-config-0.2.0-draft => wasi-config-0.2.0-rc.1}/package.wit (97%) rename components/wit/deps/{wasi-http-0.2.3 => wasi-http-0.2.8}/package.wit (94%) rename components/wit/deps/{wasi-io-0.2.3 => wasi-io-0.2.8}/package.wit (98%) create mode 100644 components/wit/deps/wasi-logging-0.1.0-draft/package.wit rename components/wit/deps/{wasi-random-0.2.3 => wasi-random-0.2.8}/package.wit (79%) delete mode 100644 components/wit/overrides/wasi-config/store.wit delete mode 100644 components/wit/overrides/wasi-config/world.wit diff --git a/components/Cargo.lock b/components/Cargo.lock index 70a8649..a1e697a 100644 --- a/components/Cargo.lock +++ b/components/Cargo.lock @@ -4,19 +4,19 @@ version = 4 [[package]] name = "anyhow" -version = "1.0.99" +version = "1.0.100" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0674a1ddeecb70197781e945de4b3b8ffb61fa939a5597bcf48503737663100" +checksum = "a23eb6b1614318a8071c9b2521f36b424b2c83db5eb3a0fead4a6c0809af6e61" [[package]] name = "bitflags" -version = "2.9.4" +version = "2.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2261d10cca569e4643e526d8dc2e62e433cc8aba21ab764233731f8d369bf394" +checksum = "812e12b5285cc515a9c72a5c1d3b6d46a19dac5acfef5265968c166106e31dd3" [[package]] name = "counter" -version = "0.1.0" +version = "0.2.0" dependencies = [ "wit-bindgen", ] @@ -29,7 +29,7 @@ checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "flights" -version = "0.1.0" +version = "0.2.0" dependencies = [ "serde", "serde_json", @@ -42,98 +42,9 @@ version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2" -[[package]] -name = "futures" -version = "0.3.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65bc07b1a8bc7c85c5f2e110c476c7389b4554ba72af57d8445ea63a576b0876" -dependencies = [ - "futures-channel", - "futures-core", - "futures-executor", - "futures-io", - "futures-sink", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-channel" -version = "0.3.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dff15bf788c671c1934e366d07e30c1814a8ef514e1af724a602e8a2fbe1b10" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05f29059c0c2090612e8d742178b0580d2dc940c837851ad723096f87af6663e" - -[[package]] -name = "futures-executor" -version = "0.3.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e28d1d997f585e54aebc3f97d39e72338912123a67330d723fdbb564d646c9f" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-io" -version = "0.3.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e5c1b78ca4aae1ac06c48a526a655760685149f0d465d21f37abfe57ce075c6" - -[[package]] -name = "futures-macro" -version = "0.3.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "futures-sink" -version = "0.3.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e575fab7d1e0dcb8d0c7bcf9a63ee213816ab51902e6d244a95819acacf1d4f7" - -[[package]] -name = "futures-task" -version = "0.3.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f90f7dce0722e95104fcb095585910c0977252f286e354b5e3bd38902cd99988" - -[[package]] -name = "futures-util" -version = "0.3.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fa08315bb612088cc391249efdc3bc77536f16c91f6cf495e6fbe85b20a4a81" -dependencies = [ - "futures-channel", - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - [[package]] name = "greeter" -version = "0.1.0" +version = "0.2.0" dependencies = [ "wit-bindgen", ] @@ -147,6 +58,12 @@ dependencies = [ "foldhash", ] +[[package]] +name = "hashbrown" +version = "0.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5419bdc4f6a9207fbeba6d11b604d481addf78ecd10c11ad51e76c2f6482748d" + [[package]] name = "heck" version = "0.5.0" @@ -155,7 +72,7 @@ checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" [[package]] name = "hotels" -version = "0.1.0" +version = "0.2.0" dependencies = [ "serde", "serde_json", @@ -170,25 +87,26 @@ checksum = "25a2bc672d1148e28034f176e01fffebb08b35768468cc954630da77a1449005" [[package]] name = "incrementor" -version = "0.1.0" +version = "0.2.0" dependencies = [ "wit-bindgen", ] [[package]] name = "indexmap" -version = "2.11.1" +version = "2.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "206a8042aec68fa4a62e8d3f7aa4ceb508177d9324faf261e1959e495b7a1921" +checksum = "6717a8d2a5a929a1a2eb43a12812498ed141a0bcfb7e8f7844fbdbe4303bba9f" dependencies = [ "equivalent", - "hashbrown", + "hashbrown 0.16.0", "serde", + "serde_core", ] [[package]] name = "intercepting-greeter" -version = "0.1.0" +version = "0.2.0" dependencies = [ "wit-bindgen", ] @@ -213,27 +131,9 @@ checksum = "34080505efa8e45a4b816c349525ebe327ceaa8559756f0356cba97ef3bf7432" [[package]] name = "memchr" -version = "2.7.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32a282da65faaf38286cf3be983213fcf1d2e2a58700e808f83f4ea9a4804bc0" - -[[package]] -name = "once_cell" -version = "1.21.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42f5e15c9953c5e4ccceeb2e7382a716482c34515315f7b03532b8b4e8393d2d" - -[[package]] -name = "pin-project-lite" -version = "0.2.16" +version = "2.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b3cff922bd51709b605d9ead9aa71031d81447142d828eb4a6eba76fe619f9b" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" +checksum = "f52b00d39961fc5b2736ea853c9cc86238e165017a493d1d5c8eac6bdc4cc273" [[package]] name = "prettyplease" @@ -247,25 +147,25 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.101" +version = "1.0.103" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ae43fd86e4158d6db51ad8e2b80f313af9cc74f5c0e03ccb87de09998732de" +checksum = "5ee95bc4ef87b8d5ba32e8b7714ccc834865276eab0aed5c9958d00ec45f49e8" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.40" +version = "1.0.42" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1885c039570dc00dcb4ff087a89e185fd56bae234ddc7f056a945bf36467248d" +checksum = "a338cc41d27e6cc6dce6cefc13a0729dfbb81c262b1f519331575dd80ef3067f" dependencies = [ "proc-macro2", ] [[package]] name = "rest-client" -version = "0.1.0" +version = "0.2.0" dependencies = [ "wit-bindgen", ] @@ -278,24 +178,34 @@ checksum = "28d3b2b1366ec20994f1fd18c3c594f05c5dd4bc44d8bb0c1c632c8d6829481f" [[package]] name = "semver" -version = "1.0.26" +version = "1.0.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56e6fa9c48d24d85fb3de5ad847117517440f6beceb7798af16b4a87d616b8d0" +checksum = "d767eb0aabc880b29956c35734170f26ed551a859dbd361d140cdbeca61ab1e2" [[package]] name = "serde" -version = "1.0.219" +version = "1.0.228" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a8e94ea7f378bd32cbbd37198a4a91436180c5bb472411e48b5ec2e2124ae9e" +dependencies = [ + "serde_core", + "serde_derive", +] + +[[package]] +name = "serde_core" +version = "1.0.228" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f0e2c6ed6606019b4e29e69dbaba95b11854410e5347d525002456dbbb786b6" +checksum = "41d385c7d4ca58e59fc732af25c3983b67ac852c1a25000afe1175de458b67ad" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.219" +version = "1.0.228" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b0276cf7f2c73365f7157c8123c21cd9a50fbbd844757af28ca1f5925fc2a00" +checksum = "d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79" dependencies = [ "proc-macro2", "quote", @@ -304,27 +214,22 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.143" +version = "1.0.145" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d401abef1d108fbd9cbaebc3e46611f4b1021f714a0597a71f41ee463f5f4a5a" +checksum = "402a6f66d8c709116cf22f558eab210f5a50187f702eb4d7e5ef38d9a7f1c79c" dependencies = [ "itoa", "memchr", "ryu", "serde", + "serde_core", ] -[[package]] -name = "slab" -version = "0.4.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a2ae44ef20feb57a68b23d846850f861394c2e02dc425a50098ae8c90267589" - [[package]] name = "syn" -version = "2.0.106" +version = "2.0.110" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ede7c438028d4436d71104916910f5bb611972c5cfd7f89b8300a8186e6fada6" +checksum = "a99801b5bd34ede4cf3fc688c5919368fea4e4814a4664359503e6015b280aea" dependencies = [ "proc-macro2", "quote", @@ -333,9 +238,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.19" +version = "1.0.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f63a545481291138910575129486daeaf8ac54aee4387fe7906919f7830c7d9d" +checksum = "9312f7c4f6ff9069b165498234ce8be658059c6728633667c526e27dc2cf1df5" [[package]] name = "unicode-xid" @@ -345,16 +250,16 @@ checksum = "ebc1c04c71510c7f702b52b7c350734c9ff1295c464a03335b00bb84fc54f853" [[package]] name = "valkey-publisher" -version = "0.1.0" +version = "0.2.0" dependencies = [ "wit-bindgen", ] [[package]] name = "wasm-encoder" -version = "0.236.1" +version = "0.241.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "724fccfd4f3c24b7e589d333fc0429c68042897a7e8a5f8694f31792471841e7" +checksum = "e01164c9dda68301e34fdae536c23ed6fe90ce6d97213ccc171eebbd3d02d6b8" dependencies = [ "leb128fmt", "wasmparser", @@ -362,9 +267,9 @@ dependencies = [ [[package]] name = "wasm-metadata" -version = "0.236.1" +version = "0.241.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c909f94a49a8de3365f3c0344f064818f1e369ff1740c5b04f455f85d454768e" +checksum = "876fe286f2fa416386deedebe8407e6f19e0b5aeaef3d03161e77a15fa80f167" dependencies = [ "anyhow", "indexmap", @@ -374,53 +279,42 @@ dependencies = [ [[package]] name = "wasmparser" -version = "0.236.1" +version = "0.241.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9b1e81f3eb254cf7404a82cee6926a4a3ccc5aad80cc3d43608a070c67aa1d7" +checksum = "46d90019b1afd4b808c263e428de644f3003691f243387d30d673211ee0cb8e8" dependencies = [ "bitflags", - "hashbrown", + "hashbrown 0.15.5", "indexmap", "semver", ] [[package]] name = "wit-bindgen" -version = "0.44.0" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04bd9ed271234163b18c92783b0d406f08ca32c232e972f207a68c7b324c44bf" +checksum = "c558f2d2929c6367736762d5593bd3276c88efa34945ed642e7bf512712bf163" dependencies = [ - "wit-bindgen-rt", + "bitflags", "wit-bindgen-rust-macro", ] [[package]] name = "wit-bindgen-core" -version = "0.44.0" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4103c7a3e178b75cd8b0b574fa199ed015e8399c9859b003865cc28834b474b" +checksum = "a64f7435c8448e456bc6e8f14e27ee4f65926cbdfe72b7bf95badeae2501bacf" dependencies = [ "anyhow", "heck", "wit-parser", ] -[[package]] -name = "wit-bindgen-rt" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "653c85dd7aee6fe6f4bded0d242406deadae9819029ce6f7d258c920c384358a" -dependencies = [ - "bitflags", - "futures", - "once_cell", -] - [[package]] name = "wit-bindgen-rust" -version = "0.44.0" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95d164b3b6fbd2b0dd8b639b1012110c0bc256519a0a6def410d4020fa8ae106" +checksum = "612651c001e0de8bfb7138af5551f80461f25caa627b64d7014a80914cf4f407" dependencies = [ "anyhow", "heck", @@ -434,9 +328,9 @@ dependencies = [ [[package]] name = "wit-bindgen-rust-macro" -version = "0.44.0" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c9100a5e1ac85e526dcd4ef49c3ff7689e026fa5e56e2a2047fd377fc682e02" +checksum = "16c64812d84284d45ce7d7371dc9eb0bcda2f0f747128bd1b4dae1e08217bad3" dependencies = [ "anyhow", "prettyplease", @@ -449,9 +343,9 @@ dependencies = [ [[package]] name = "wit-component" -version = "0.236.1" +version = "0.241.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3622959ed7ed6341c38e5aa35af243632534b0a36226852faa802939ce11e00f" +checksum = "1fd0c57df25e7ee612d946d3b7646c1ddb2310f8280aa2c17e543b66e0812241" dependencies = [ "anyhow", "bitflags", @@ -468,9 +362,9 @@ dependencies = [ [[package]] name = "wit-parser" -version = "0.236.1" +version = "0.241.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16e4833a20cd6e85d6abfea0e63a399472d6f88c6262957c17f546879a80ba15" +checksum = "09ef1c6ad67f35c831abd4039c02894de97034100899614d1c44e2268ad01c91" dependencies = [ "anyhow", "id-arena", diff --git a/components/Cargo.toml b/components/Cargo.toml index 95e82c1..bc51806 100644 --- a/components/Cargo.toml +++ b/components/Cargo.toml @@ -12,4 +12,4 @@ members = [ resolver = "3" [workspace.dependencies] -wit-bindgen = "0.44" +wit-bindgen = "0.48" diff --git a/components/build.sh b/components/build.sh index 18fd9a2..3ee0bee 100755 --- a/components/build.sh +++ b/components/build.sh @@ -21,7 +21,7 @@ wac plug ./lib/greeter.wasm --plug ./lib/empty-config.wasm -o ./lib/hello.wasm static-config -p greeting="Aloha" -o ./lib/aloha-config.wasm wac plug ./lib/greeter.wasm --plug ./lib/aloha-config.wasm -o ./lib/aloha.wasm -wkg oci pull -o ./lib/valkey-client.wasm ghcr.io/componentized/valkey/valkey-client:v0.1.1 +wkg oci pull -o ./lib/valkey-client.wasm ghcr.io/componentized/valkey/valkey-client:v0.2.0 wac plug ./lib/incrementor.wasm --plug ./lib/valkey-client.wasm -o ./lib/valkey-incrementor.wasm wac plug ./lib/valkey-incrementor.wasm --plug ./lib/empty-config.wasm -o ./lib/default-incrementor.wasm diff --git a/components/calculator/calculator.wat b/components/calculator/calculator.wat index 87b664c..7474e0b 100644 --- a/components/calculator/calculator.wat +++ b/components/calculator/calculator.wat @@ -1,22 +1,22 @@ (module - (func (export "add") (param f32 f32) (result f32) + (func (export "add") (param i32 i32) (result i32) local.get 0 local.get 1 - f32.add + i32.add ) - (func (export "subtract") (param f32 f32) (result f32) + (func (export "subtract") (param i32 i32) (result i32) local.get 0 local.get 1 - f32.sub + i32.sub ) - (func (export "multiply") (param f32 f32) (result f32) + (func (export "multiply") (param i32 i32) (result i32) local.get 0 local.get 1 - f32.mul + i32.mul ) - (func (export "divide") (param f32 f32) (result f32) + (func (export "divide") (param i32 i32) (result i32) local.get 0 local.get 1 - f32.div + i32.div_s ) ) diff --git a/components/calculator/componentize.sh b/components/calculator/componentize.sh index 0f391f0..e6559a7 100755 --- a/components/calculator/componentize.sh +++ b/components/calculator/componentize.sh @@ -2,7 +2,7 @@ wat2wasm calculator.wat -o calculator.core.wasm -sed 's/(export "\([^"]*\)")/(export "modulewise:demo\/calculator@0.1.0#\1")/g' calculator.wat | \ +sed 's/(export "\([^"]*\)")/(export "modulewise:demo\/calculator@0.2.0#\1")/g' calculator.wat | \ wat2wasm /dev/stdin --output=- | \ wasm-tools component embed ../wit -w calculator-world - | \ wasm-tools component new - -o calculator.wasm diff --git a/components/counter/Cargo.toml b/components/counter/Cargo.toml index 11d4f8a..738a32a 100644 --- a/components/counter/Cargo.toml +++ b/components/counter/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "counter" -version = "0.1.0" +version = "0.2.0" edition = "2024" [lib] diff --git a/components/flights/Cargo.toml b/components/flights/Cargo.toml index b3bc832..4a680cc 100644 --- a/components/flights/Cargo.toml +++ b/components/flights/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "flights" -version = "0.1.0" +version = "0.2.0" edition = "2024" [lib] diff --git a/components/greeter/Cargo.toml b/components/greeter/Cargo.toml index 89b884d..46d1cb1 100644 --- a/components/greeter/Cargo.toml +++ b/components/greeter/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "greeter" -version = "0.1.0" +version = "0.2.0" edition = "2024" [lib] diff --git a/components/hotels/Cargo.toml b/components/hotels/Cargo.toml index cba28ba..e44c116 100644 --- a/components/hotels/Cargo.toml +++ b/components/hotels/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "hotels" -version = "0.1.0" +version = "0.2.0" edition = "2024" [lib] diff --git a/components/incrementor/Cargo.toml b/components/incrementor/Cargo.toml index 7392e31..47441e4 100644 --- a/components/incrementor/Cargo.toml +++ b/components/incrementor/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "incrementor" -version = "0.1.0" +version = "0.2.0" edition = "2024" [lib] diff --git a/components/intercepting-greeter/Cargo.toml b/components/intercepting-greeter/Cargo.toml index 7790680..f62f60d 100644 --- a/components/intercepting-greeter/Cargo.toml +++ b/components/intercepting-greeter/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "intercepting-greeter" -version = "0.1.0" +version = "0.2.0" edition = "2024" [lib] diff --git a/components/publish.sh b/components/publish.sh index db6056d..114aedb 100755 --- a/components/publish.sh +++ b/components/publish.sh @@ -5,7 +5,7 @@ set -euo pipefail COMPONENTS=("calculator" "hello") for COMPONENT in "${COMPONENTS[@]}"; do - VERSION=0.1.0 + VERSION=0.2.0 wkg oci push \ --annotation "org.opencontainers.image.title=${COMPONENT}" \ --annotation "org.opencontainers.image.description=${COMPONENT} component for modulewise demos" \ diff --git a/components/rest-client/Cargo.toml b/components/rest-client/Cargo.toml index e4ac4df..2104664 100644 --- a/components/rest-client/Cargo.toml +++ b/components/rest-client/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "rest-client" -version = "0.1.0" +version = "0.2.0" edition = "2024" [lib] diff --git a/components/valkey-publisher/Cargo.toml b/components/valkey-publisher/Cargo.toml index 431d6e1..c04c8d6 100644 --- a/components/valkey-publisher/Cargo.toml +++ b/components/valkey-publisher/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "valkey-publisher" -version = "0.1.0" +version = "0.2.0" edition = "2024" [lib] diff --git a/components/wit/calculator.wit b/components/wit/calculator.wit index 712acfa..57f7ff2 100644 --- a/components/wit/calculator.wit +++ b/components/wit/calculator.wit @@ -2,16 +2,16 @@ interface calculator { /// add two numbers - add: func(a: f32, b: f32) -> f32; + add: func(a: s32, b: s32) -> s32; /// subtract the second number from the first - subtract: func(a: f32, b: f32) -> f32; + subtract: func(a: s32, b: s32) -> s32; /// multiply two numbers - multiply: func(a: f32, b: f32) -> f32; + multiply: func(a: s32, b: s32) -> s32; /// divide the first number by the second - divide: func(a: f32, b: f32) -> f32; + divide: func(a: s32, b: s32) -> s32; } /// the calculator world diff --git a/components/wit/counter.wit b/components/wit/counter.wit index 7911708..9abce7a 100644 --- a/components/wit/counter.wit +++ b/components/wit/counter.wit @@ -6,7 +6,7 @@ interface counter { /// the counter world world counter-world { - include wasi:config/imports@0.2.0-draft; + import wasi:config/store@0.2.0-rc.1; import incrementor; export counter; } diff --git a/components/wit/deps/wasi-cli-0.2.3/package.wit b/components/wit/deps/wasi-cli-0.2.8/package.wit similarity index 53% rename from components/wit/deps/wasi-cli-0.2.3/package.wit rename to components/wit/deps/wasi-cli-0.2.8/package.wit index 3c4deca..8e71725 100644 --- a/components/wit/deps/wasi-cli-0.2.3/package.wit +++ b/components/wit/deps/wasi-cli-0.2.8/package.wit @@ -1,19 +1,19 @@ -package wasi:cli@0.2.3; +package wasi:cli@0.2.8; interface stdout { - use wasi:io/streams@0.2.3.{output-stream}; + use wasi:io/streams@0.2.8.{output-stream}; get-stdout: func() -> output-stream; } interface stderr { - use wasi:io/streams@0.2.3.{output-stream}; + use wasi:io/streams@0.2.8.{output-stream}; get-stderr: func() -> output-stream; } interface stdin { - use wasi:io/streams@0.2.3.{input-stream}; + use wasi:io/streams@0.2.8.{input-stream}; get-stdin: func() -> input-stream; } diff --git a/components/wit/deps/wasi-clocks-0.2.3/package.wit b/components/wit/deps/wasi-clocks-0.2.3/package.wit deleted file mode 100644 index 92f2662..0000000 --- a/components/wit/deps/wasi-clocks-0.2.3/package.wit +++ /dev/null @@ -1,29 +0,0 @@ -package wasi:clocks@0.2.3; - -interface monotonic-clock { - use wasi:io/poll@0.2.3.{pollable}; - - type instant = u64; - - type duration = u64; - - now: func() -> instant; - - resolution: func() -> duration; - - subscribe-instant: func(when: instant) -> pollable; - - subscribe-duration: func(when: duration) -> pollable; -} - -interface wall-clock { - record datetime { - seconds: u64, - nanoseconds: u32, - } - - now: func() -> datetime; - - resolution: func() -> datetime; -} - diff --git a/components/wit/deps/wasi-clocks-0.2.8/package.wit b/components/wit/deps/wasi-clocks-0.2.8/package.wit new file mode 100644 index 0000000..918bbea --- /dev/null +++ b/components/wit/deps/wasi-clocks-0.2.8/package.wit @@ -0,0 +1,162 @@ +package wasi:clocks@0.2.8; + +/// WASI Monotonic Clock is a clock API intended to let users measure elapsed +/// time. +/// +/// It is intended to be portable at least between Unix-family platforms and +/// Windows. +/// +/// A monotonic clock is a clock which has an unspecified initial value, and +/// successive reads of the clock will produce non-decreasing values. +@since(version = 0.2.0) +interface monotonic-clock { + @since(version = 0.2.0) + use wasi:io/poll@0.2.8.{pollable}; + + /// An instant in time, in nanoseconds. An instant is relative to an + /// unspecified initial value, and can only be compared to instances from + /// the same monotonic-clock. + @since(version = 0.2.0) + type instant = u64; + + /// A duration of time, in nanoseconds. + @since(version = 0.2.0) + type duration = u64; + + /// Read the current value of the clock. + /// + /// The clock is monotonic, therefore calling this function repeatedly will + /// produce a sequence of non-decreasing values. + /// + /// For completeness, this function traps if it's not possible to represent + /// the value of the clock in an `instant`. Consequently, implementations + /// should ensure that the starting time is low enough to avoid the + /// possibility of overflow in practice. + @since(version = 0.2.0) + now: func() -> instant; + + /// Query the resolution of the clock. Returns the duration of time + /// corresponding to a clock tick. + @since(version = 0.2.0) + resolution: func() -> duration; + + /// Create a `pollable` which will resolve once the specified instant + /// has occurred. + @since(version = 0.2.0) + subscribe-instant: func(when: instant) -> pollable; + + /// Create a `pollable` that will resolve after the specified duration has + /// elapsed from the time this function is invoked. + @since(version = 0.2.0) + subscribe-duration: func(when: duration) -> pollable; +} + +/// WASI Wall Clock is a clock API intended to let users query the current +/// time. The name "wall" makes an analogy to a "clock on the wall", which +/// is not necessarily monotonic as it may be reset. +/// +/// It is intended to be portable at least between Unix-family platforms and +/// Windows. +/// +/// A wall clock is a clock which measures the date and time according to +/// some external reference. +/// +/// External references may be reset, so this clock is not necessarily +/// monotonic, making it unsuitable for measuring elapsed time. +/// +/// It is intended for reporting the current date and time for humans. +@since(version = 0.2.0) +interface wall-clock { + /// A time and date in seconds plus nanoseconds. + @since(version = 0.2.0) + record datetime { + seconds: u64, + nanoseconds: u32, + } + + /// Read the current value of the clock. + /// + /// This clock is not monotonic, therefore calling this function repeatedly + /// will not necessarily produce a sequence of non-decreasing values. + /// + /// The returned timestamps represent the number of seconds since + /// 1970-01-01T00:00:00Z, also known as [POSIX's Seconds Since the Epoch], + /// also known as [Unix Time]. + /// + /// The nanoseconds field of the output is always less than 1000000000. + /// + /// [POSIX's Seconds Since the Epoch]: https://pubs.opengroup.org/onlinepubs/9699919799/xrat/V4_xbd_chap04.html#tag_21_04_16 + /// [Unix Time]: https://en.wikipedia.org/wiki/Unix_time + @since(version = 0.2.0) + now: func() -> datetime; + + /// Query the resolution of the clock. + /// + /// The nanoseconds field of the output is always less than 1000000000. + @since(version = 0.2.0) + resolution: func() -> datetime; +} + +@unstable(feature = clocks-timezone) +interface timezone { + @unstable(feature = clocks-timezone) + use wall-clock.{datetime}; + + /// Information useful for displaying the timezone of a specific `datetime`. + /// + /// This information may vary within a single `timezone` to reflect daylight + /// saving time adjustments. + @unstable(feature = clocks-timezone) + record timezone-display { + /// The number of seconds difference between UTC time and the local + /// time of the timezone. + /// + /// The returned value will always be less than 86400 which is the + /// number of seconds in a day (24*60*60). + /// + /// In implementations that do not expose an actual time zone, this + /// should return 0. + utc-offset: s32, + /// The abbreviated name of the timezone to display to a user. The name + /// `UTC` indicates Coordinated Universal Time. Otherwise, this should + /// reference local standards for the name of the time zone. + /// + /// In implementations that do not expose an actual time zone, this + /// should be the string `UTC`. + /// + /// In time zones that do not have an applicable name, a formatted + /// representation of the UTC offset may be returned, such as `-04:00`. + name: string, + /// Whether daylight saving time is active. + /// + /// In implementations that do not expose an actual time zone, this + /// should return false. + in-daylight-saving-time: bool, + } + + /// Return information needed to display the given `datetime`. This includes + /// the UTC offset, the time zone name, and a flag indicating whether + /// daylight saving time is active. + /// + /// If the timezone cannot be determined for the given `datetime`, return a + /// `timezone-display` for `UTC` with a `utc-offset` of 0 and no daylight + /// saving time. + @unstable(feature = clocks-timezone) + display: func(when: datetime) -> timezone-display; + + /// The same as `display`, but only return the UTC offset. + @unstable(feature = clocks-timezone) + utc-offset: func(when: datetime) -> s32; +} + +@since(version = 0.2.0) +world imports { + @since(version = 0.2.0) + import wasi:io/poll@0.2.8; + @since(version = 0.2.0) + import monotonic-clock; + @since(version = 0.2.0) + import wall-clock; + @unstable(feature = clocks-timezone) + import timezone; +} diff --git a/components/wit/deps/wasi-config-0.2.0-draft/package.wit b/components/wit/deps/wasi-config-0.2.0-rc.1/package.wit similarity index 97% rename from components/wit/deps/wasi-config-0.2.0-draft/package.wit rename to components/wit/deps/wasi-config-0.2.0-rc.1/package.wit index a4cdf94..d8950ee 100644 --- a/components/wit/deps/wasi-config-0.2.0-draft/package.wit +++ b/components/wit/deps/wasi-config-0.2.0-rc.1/package.wit @@ -1,4 +1,4 @@ -package wasi:config@0.2.0-draft; +package wasi:config@0.2.0-rc.1; interface store { /// An error type that encapsulates the different errors that can occur fetching configuration values. diff --git a/components/wit/deps/wasi-http-0.2.3/package.wit b/components/wit/deps/wasi-http-0.2.8/package.wit similarity index 94% rename from components/wit/deps/wasi-http-0.2.3/package.wit rename to components/wit/deps/wasi-http-0.2.8/package.wit index 932f089..a644ead 100644 --- a/components/wit/deps/wasi-http-0.2.3/package.wit +++ b/components/wit/deps/wasi-http-0.2.8/package.wit @@ -1,4 +1,4 @@ -package wasi:http@0.2.3; +package wasi:http@0.2.8; /// This interface defines all of the types and methods for implementing /// HTTP Requests and Responses, both incoming and outgoing, as well as @@ -6,13 +6,13 @@ package wasi:http@0.2.3; @since(version = 0.2.0) interface types { @since(version = 0.2.0) - use wasi:clocks/monotonic-clock@0.2.3.{duration}; + use wasi:clocks/monotonic-clock@0.2.8.{duration}; @since(version = 0.2.0) - use wasi:io/streams@0.2.3.{input-stream, output-stream}; + use wasi:io/streams@0.2.8.{input-stream, output-stream}; @since(version = 0.2.0) - use wasi:io/error@0.2.3.{error as io-error}; + use wasi:io/error@0.2.8.{error as io-error}; @since(version = 0.2.0) - use wasi:io/poll@0.2.3.{pollable}; + use wasi:io/poll@0.2.8.{pollable}; /// This type corresponds to HTTP standard Methods. @since(version = 0.2.0) @@ -59,7 +59,7 @@ interface types { } /// These cases are inspired by the IANA HTTP Proxy Error Types: - /// + /// @since(version = 0.2.0) variant error-code { DNS-timeout, @@ -156,7 +156,7 @@ interface types { /// A `fields` may be mutable or immutable. A `fields` created using the /// constructor, `from-list`, or `clone` will be mutable, but a `fields` /// resource given by other means (including, but not limited to, - /// `incoming-request.headers`, `outgoing-request.headers`) might be be + /// `incoming-request.headers`, `outgoing-request.headers`) might be /// immutable. In an immutable fields, the `set`, `append`, and `delete` /// operations will fail with `header-error.immutable`. @since(version = 0.2.0) @@ -389,6 +389,18 @@ interface types { /// other argument to `incoming-handler.handle`. @since(version = 0.2.0) resource response-outparam { + /// Send an HTTP 1xx response. + /// + /// Unlike `response-outparam.set`, this does not consume the + /// `response-outparam`, allowing the guest to send an arbitrary number of + /// informational responses before sending the final response using + /// `response-outparam.set`. + /// + /// This will return an `HTTP-protocol-error` if `status` is not in the + /// range [100-199], or an `internal-error` if the implementation does not + /// support informational responses. + @unstable(feature = informational-outbound-responses) + send-informational: func(status: u16, headers: headers) -> result<_, error-code>; /// Set the value of the `response-outparam` to either send a response, /// or indicate an error. /// @@ -665,23 +677,23 @@ interface outgoing-handler { @since(version = 0.2.0) world imports { @since(version = 0.2.0) - import wasi:io/poll@0.2.3; + import wasi:io/poll@0.2.8; @since(version = 0.2.0) - import wasi:clocks/monotonic-clock@0.2.3; + import wasi:clocks/monotonic-clock@0.2.8; @since(version = 0.2.0) - import wasi:clocks/wall-clock@0.2.3; + import wasi:clocks/wall-clock@0.2.8; @since(version = 0.2.0) - import wasi:random/random@0.2.3; + import wasi:random/random@0.2.8; @since(version = 0.2.0) - import wasi:io/error@0.2.3; + import wasi:io/error@0.2.8; @since(version = 0.2.0) - import wasi:io/streams@0.2.3; + import wasi:io/streams@0.2.8; @since(version = 0.2.0) - import wasi:cli/stdout@0.2.3; + import wasi:cli/stdout@0.2.8; @since(version = 0.2.0) - import wasi:cli/stderr@0.2.3; + import wasi:cli/stderr@0.2.8; @since(version = 0.2.0) - import wasi:cli/stdin@0.2.3; + import wasi:cli/stdin@0.2.8; @since(version = 0.2.0) import types; @since(version = 0.2.0) @@ -694,23 +706,23 @@ world imports { @since(version = 0.2.0) world proxy { @since(version = 0.2.0) - import wasi:io/poll@0.2.3; + import wasi:io/poll@0.2.8; @since(version = 0.2.0) - import wasi:clocks/monotonic-clock@0.2.3; + import wasi:clocks/monotonic-clock@0.2.8; @since(version = 0.2.0) - import wasi:clocks/wall-clock@0.2.3; + import wasi:clocks/wall-clock@0.2.8; @since(version = 0.2.0) - import wasi:random/random@0.2.3; + import wasi:random/random@0.2.8; @since(version = 0.2.0) - import wasi:io/error@0.2.3; + import wasi:io/error@0.2.8; @since(version = 0.2.0) - import wasi:io/streams@0.2.3; + import wasi:io/streams@0.2.8; @since(version = 0.2.0) - import wasi:cli/stdout@0.2.3; + import wasi:cli/stdout@0.2.8; @since(version = 0.2.0) - import wasi:cli/stderr@0.2.3; + import wasi:cli/stderr@0.2.8; @since(version = 0.2.0) - import wasi:cli/stdin@0.2.3; + import wasi:cli/stdin@0.2.8; @since(version = 0.2.0) import types; @since(version = 0.2.0) diff --git a/components/wit/deps/wasi-io-0.2.3/package.wit b/components/wit/deps/wasi-io-0.2.8/package.wit similarity index 98% rename from components/wit/deps/wasi-io-0.2.3/package.wit rename to components/wit/deps/wasi-io-0.2.8/package.wit index adcf1f4..19fd428 100644 --- a/components/wit/deps/wasi-io-0.2.3/package.wit +++ b/components/wit/deps/wasi-io-0.2.8/package.wit @@ -1,4 +1,4 @@ -package wasi:io@0.2.3; +package wasi:io@0.2.8; interface poll { resource pollable { diff --git a/components/wit/deps/wasi-logging-0.1.0-draft/package.wit b/components/wit/deps/wasi-logging-0.1.0-draft/package.wit new file mode 100644 index 0000000..164cb5b --- /dev/null +++ b/components/wit/deps/wasi-logging-0.1.0-draft/package.wit @@ -0,0 +1,36 @@ +package wasi:logging@0.1.0-draft; + +/// WASI Logging is a logging API intended to let users emit log messages with +/// simple priority levels and context values. +interface logging { + /// A log level, describing a kind of message. + enum level { + /// Describes messages about the values of variables and the flow of + /// control within a program. + trace, + /// Describes messages likely to be of interest to someone debugging a + /// program. + debug, + /// Describes messages likely to be of interest to someone monitoring a + /// program. + info, + /// Describes messages indicating hazardous situations. + warn, + /// Describes messages indicating serious errors. + error, + /// Describes messages indicating fatal errors. + critical, + } + + /// Emit a log message. + /// + /// A log message has a `level` describing what kind of message is being + /// sent, a context, which is an uninterpreted string meant to help + /// consumers group similar messages, and a string containing the message + /// text. + log: func(level: level, context: string, message: string); +} + +world imports { + import logging; +} diff --git a/components/wit/deps/wasi-random-0.2.3/package.wit b/components/wit/deps/wasi-random-0.2.8/package.wit similarity index 79% rename from components/wit/deps/wasi-random-0.2.3/package.wit rename to components/wit/deps/wasi-random-0.2.8/package.wit index 4be137c..342c0dc 100644 --- a/components/wit/deps/wasi-random-0.2.3/package.wit +++ b/components/wit/deps/wasi-random-0.2.8/package.wit @@ -1,4 +1,4 @@ -package wasi:random@0.2.3; +package wasi:random@0.2.8; interface random { get-random-bytes: func(len: u64) -> list; diff --git a/components/wit/flights.wit b/components/wit/flights.wit index 8945bb4..5e83b08 100644 --- a/components/wit/flights.wit +++ b/components/wit/flights.wit @@ -23,7 +23,7 @@ interface flights { } world flights-world { - include wasi:config/imports@0.2.0-draft; + import wasi:config/store@0.2.0-rc.1; import rest-client; export flights; } diff --git a/components/wit/greeter.wit b/components/wit/greeter.wit index 4868ef4..45e6baa 100644 --- a/components/wit/greeter.wit +++ b/components/wit/greeter.wit @@ -4,6 +4,6 @@ interface greeter { } world greeter-world { - include wasi:config/imports@0.2.0-draft; + import wasi:config/store@0.2.0-rc.1; export greeter; } diff --git a/components/wit/hotels.wit b/components/wit/hotels.wit index 65d403b..a4282d4 100644 --- a/components/wit/hotels.wit +++ b/components/wit/hotels.wit @@ -21,7 +21,7 @@ interface hotels { } world hotels-world { - include wasi:config/imports@0.2.0-draft; + import wasi:config/store@0.2.0-rc.1; import rest-client; export hotels; } diff --git a/components/wit/incrementor.wit b/components/wit/incrementor.wit index a246dfd..8f22d17 100644 --- a/components/wit/incrementor.wit +++ b/components/wit/incrementor.wit @@ -3,7 +3,7 @@ interface incrementor { } world incrementor-world { - import wasi:config/store@0.2.0-draft; + import wasi:config/store@0.2.0-rc.1; import wasi:keyvalue/atomics@0.2.0-draft2; export incrementor; } diff --git a/components/wit/intercepting-greeter.wit b/components/wit/intercepting-greeter.wit index 2f88b72..ab47b42 100644 --- a/components/wit/intercepting-greeter.wit +++ b/components/wit/intercepting-greeter.wit @@ -1,5 +1,5 @@ world intercepting-greeter-world { export greeter; import greeter; - import wasi:config/store@0.2.0-draft; + import wasi:config/store@0.2.0-rc.1; } diff --git a/components/wit/overrides/wasi-config/store.wit b/components/wit/overrides/wasi-config/store.wit deleted file mode 100644 index 794379a..0000000 --- a/components/wit/overrides/wasi-config/store.wit +++ /dev/null @@ -1,30 +0,0 @@ -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. - upstream(string), - /// This indicates an error from an I/O operation. - /// As this could be almost _anything_ (such as a file read, network connection, etc), - /// the error message is a string. - /// Depending on how this ends up being consumed, - /// we may consider moving this to use the `wasi:io/error` type instead. - /// For simplicity right now in supporting multiple implementations, it is being left as a string. - io(string), - } - - /// 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, 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/components/wit/overrides/wasi-config/world.wit b/components/wit/overrides/wasi-config/world.wit deleted file mode 100644 index 1dc56d1..0000000 --- a/components/wit/overrides/wasi-config/world.wit +++ /dev/null @@ -1,6 +0,0 @@ -package wasi:config@0.2.0-draft; - -world imports { - /// The interface for wasi:config/store - import store; -} diff --git a/components/wit/package.wit b/components/wit/package.wit index 9b880ed..a072270 100644 --- a/components/wit/package.wit +++ b/components/wit/package.wit @@ -1 +1 @@ -package modulewise:demo@0.1.0; +package modulewise:demo@0.2.0; diff --git a/components/wit/publisher.wit b/components/wit/publisher.wit index 847c2bd..ef6c02f 100644 --- a/components/wit/publisher.wit +++ b/components/wit/publisher.wit @@ -3,7 +3,7 @@ interface publisher { } world valkey-publisher-world { - include wasi:config/imports@0.2.0-draft; + import wasi:config/store@0.2.0-rc.1; import componentized:valkey/store; export publisher; } diff --git a/components/wit/rest-client.wit b/components/wit/rest-client.wit index 21464e1..eb63daf 100644 --- a/components/wit/rest-client.wit +++ b/components/wit/rest-client.wit @@ -14,5 +14,5 @@ interface rest-client { world rest-client-world { export rest-client; - import wasi:http/outgoing-handler@0.2.3; + import wasi:http/outgoing-handler@0.2.8; } diff --git a/components/wkg.lock b/components/wkg.lock index a782ccc..1fb2298 100644 --- a/components/wkg.lock +++ b/components/wkg.lock @@ -2,11 +2,38 @@ # It is not intended for manual editing. version = 1 +[[packages]] +name = "wasi:clocks" +registry = "wasi.dev" + +[[packages.versions]] +requirement = "=0.2.8" +version = "0.2.8" +digest = "sha256:d47fd7df9c3f26ef5f86e3309a58f850db3ac0032b28ec285d6129c6a8f4a684" + +[[packages]] +name = "wasi:config" +registry = "wasi.dev" + +[[packages.versions]] +requirement = "=0.2.0-rc.1" +version = "0.2.0-rc.1" +digest = "sha256:1b7f1b0fd07bb4cede16c6a6ec8852815dfb924639a78735fc7bdffdc164485d" + [[packages]] name = "wasi:http" registry = "wasi.dev" [[packages.versions]] -requirement = "=0.2.3" -version = "0.2.3" -digest = "sha256:e526c1586efc94cd148e33725139be05c4bb58ba20466d348282bd8dc3999f1d" +requirement = "=0.2.8" +version = "0.2.8" +digest = "sha256:efac1616dceaa5a7d0423a3732b0addf74013974ae90feeb1081555479dc5500" + +[[packages]] +name = "wasi:logging" +registry = "wasi.dev" + +[[packages.versions]] +requirement = "=0.1.0-draft" +version = "0.1.0-draft" +digest = "sha256:09621a45b12b0a9cddc798517f778aac0e5ae4bd234077b3d70758d6cf625580" diff --git a/components/wkg.toml b/components/wkg.toml index 1e2ab99..6b158c9 100644 --- a/components/wkg.toml +++ b/components/wkg.toml @@ -1,4 +1,3 @@ [overrides] -"wasi:config" = { path = "./wit/overrides/wasi-config" } -"wasi:keyvalue" = { path = "./wit/overrides/wasi-keyvalue" } "componentized:valkey" = { path = "./wit/overrides/componentized-valkey" } +"wasi:keyvalue" = { path = "./wit/overrides/wasi-keyvalue" } From 8ea0cff79b35b26feb9f572cacec36e1e06e23e2 Mon Sep 17 00:00:00 2001 From: markfisher Date: Mon, 17 Nov 2025 20:30:41 -0500 Subject: [PATCH 2/2] wasmtime is on 0.2.6 Signed-off-by: markfisher --- .../package.wit | 8 ++-- .../package.wit | 11 ++--- .../package.wit | 46 +++++++++---------- .../package.wit | 2 +- .../package.wit | 2 +- components/wit/rest-client.wit | 2 +- components/wkg.lock | 12 ++--- 7 files changed, 39 insertions(+), 44 deletions(-) rename components/wit/deps/{wasi-cli-0.2.8 => wasi-cli-0.2.6}/package.wit (53%) rename components/wit/deps/{wasi-clocks-0.2.8 => wasi-clocks-0.2.6}/package.wit (93%) rename components/wit/deps/{wasi-http-0.2.8 => wasi-http-0.2.6}/package.wit (97%) rename components/wit/deps/{wasi-io-0.2.8 => wasi-io-0.2.6}/package.wit (98%) rename components/wit/deps/{wasi-random-0.2.8 => wasi-random-0.2.6}/package.wit (79%) diff --git a/components/wit/deps/wasi-cli-0.2.8/package.wit b/components/wit/deps/wasi-cli-0.2.6/package.wit similarity index 53% rename from components/wit/deps/wasi-cli-0.2.8/package.wit rename to components/wit/deps/wasi-cli-0.2.6/package.wit index 8e71725..81e1df3 100644 --- a/components/wit/deps/wasi-cli-0.2.8/package.wit +++ b/components/wit/deps/wasi-cli-0.2.6/package.wit @@ -1,19 +1,19 @@ -package wasi:cli@0.2.8; +package wasi:cli@0.2.6; interface stdout { - use wasi:io/streams@0.2.8.{output-stream}; + use wasi:io/streams@0.2.6.{output-stream}; get-stdout: func() -> output-stream; } interface stderr { - use wasi:io/streams@0.2.8.{output-stream}; + use wasi:io/streams@0.2.6.{output-stream}; get-stderr: func() -> output-stream; } interface stdin { - use wasi:io/streams@0.2.8.{input-stream}; + use wasi:io/streams@0.2.6.{input-stream}; get-stdin: func() -> input-stream; } diff --git a/components/wit/deps/wasi-clocks-0.2.8/package.wit b/components/wit/deps/wasi-clocks-0.2.6/package.wit similarity index 93% rename from components/wit/deps/wasi-clocks-0.2.8/package.wit rename to components/wit/deps/wasi-clocks-0.2.6/package.wit index 918bbea..d638f1a 100644 --- a/components/wit/deps/wasi-clocks-0.2.8/package.wit +++ b/components/wit/deps/wasi-clocks-0.2.6/package.wit @@ -1,4 +1,4 @@ -package wasi:clocks@0.2.8; +package wasi:clocks@0.2.6; /// WASI Monotonic Clock is a clock API intended to let users measure elapsed /// time. @@ -11,7 +11,7 @@ package wasi:clocks@0.2.8; @since(version = 0.2.0) interface monotonic-clock { @since(version = 0.2.0) - use wasi:io/poll@0.2.8.{pollable}; + use wasi:io/poll@0.2.6.{pollable}; /// An instant in time, in nanoseconds. An instant is relative to an /// unspecified initial value, and can only be compared to instances from @@ -27,11 +27,6 @@ interface monotonic-clock { /// /// The clock is monotonic, therefore calling this function repeatedly will /// produce a sequence of non-decreasing values. - /// - /// For completeness, this function traps if it's not possible to represent - /// the value of the clock in an `instant`. Consequently, implementations - /// should ensure that the starting time is low enough to avoid the - /// possibility of overflow in practice. @since(version = 0.2.0) now: func() -> instant; @@ -152,7 +147,7 @@ interface timezone { @since(version = 0.2.0) world imports { @since(version = 0.2.0) - import wasi:io/poll@0.2.8; + import wasi:io/poll@0.2.6; @since(version = 0.2.0) import monotonic-clock; @since(version = 0.2.0) diff --git a/components/wit/deps/wasi-http-0.2.8/package.wit b/components/wit/deps/wasi-http-0.2.6/package.wit similarity index 97% rename from components/wit/deps/wasi-http-0.2.8/package.wit rename to components/wit/deps/wasi-http-0.2.6/package.wit index a644ead..eb1b25f 100644 --- a/components/wit/deps/wasi-http-0.2.8/package.wit +++ b/components/wit/deps/wasi-http-0.2.6/package.wit @@ -1,4 +1,4 @@ -package wasi:http@0.2.8; +package wasi:http@0.2.6; /// This interface defines all of the types and methods for implementing /// HTTP Requests and Responses, both incoming and outgoing, as well as @@ -6,13 +6,13 @@ package wasi:http@0.2.8; @since(version = 0.2.0) interface types { @since(version = 0.2.0) - use wasi:clocks/monotonic-clock@0.2.8.{duration}; + use wasi:clocks/monotonic-clock@0.2.6.{duration}; @since(version = 0.2.0) - use wasi:io/streams@0.2.8.{input-stream, output-stream}; + use wasi:io/streams@0.2.6.{input-stream, output-stream}; @since(version = 0.2.0) - use wasi:io/error@0.2.8.{error as io-error}; + use wasi:io/error@0.2.6.{error as io-error}; @since(version = 0.2.0) - use wasi:io/poll@0.2.8.{pollable}; + use wasi:io/poll@0.2.6.{pollable}; /// This type corresponds to HTTP standard Methods. @since(version = 0.2.0) @@ -677,23 +677,23 @@ interface outgoing-handler { @since(version = 0.2.0) world imports { @since(version = 0.2.0) - import wasi:io/poll@0.2.8; + import wasi:io/poll@0.2.6; @since(version = 0.2.0) - import wasi:clocks/monotonic-clock@0.2.8; + import wasi:clocks/monotonic-clock@0.2.6; @since(version = 0.2.0) - import wasi:clocks/wall-clock@0.2.8; + import wasi:clocks/wall-clock@0.2.6; @since(version = 0.2.0) - import wasi:random/random@0.2.8; + import wasi:random/random@0.2.6; @since(version = 0.2.0) - import wasi:io/error@0.2.8; + import wasi:io/error@0.2.6; @since(version = 0.2.0) - import wasi:io/streams@0.2.8; + import wasi:io/streams@0.2.6; @since(version = 0.2.0) - import wasi:cli/stdout@0.2.8; + import wasi:cli/stdout@0.2.6; @since(version = 0.2.0) - import wasi:cli/stderr@0.2.8; + import wasi:cli/stderr@0.2.6; @since(version = 0.2.0) - import wasi:cli/stdin@0.2.8; + import wasi:cli/stdin@0.2.6; @since(version = 0.2.0) import types; @since(version = 0.2.0) @@ -706,23 +706,23 @@ world imports { @since(version = 0.2.0) world proxy { @since(version = 0.2.0) - import wasi:io/poll@0.2.8; + import wasi:io/poll@0.2.6; @since(version = 0.2.0) - import wasi:clocks/monotonic-clock@0.2.8; + import wasi:clocks/monotonic-clock@0.2.6; @since(version = 0.2.0) - import wasi:clocks/wall-clock@0.2.8; + import wasi:clocks/wall-clock@0.2.6; @since(version = 0.2.0) - import wasi:random/random@0.2.8; + import wasi:random/random@0.2.6; @since(version = 0.2.0) - import wasi:io/error@0.2.8; + import wasi:io/error@0.2.6; @since(version = 0.2.0) - import wasi:io/streams@0.2.8; + import wasi:io/streams@0.2.6; @since(version = 0.2.0) - import wasi:cli/stdout@0.2.8; + import wasi:cli/stdout@0.2.6; @since(version = 0.2.0) - import wasi:cli/stderr@0.2.8; + import wasi:cli/stderr@0.2.6; @since(version = 0.2.0) - import wasi:cli/stdin@0.2.8; + import wasi:cli/stdin@0.2.6; @since(version = 0.2.0) import types; @since(version = 0.2.0) diff --git a/components/wit/deps/wasi-io-0.2.8/package.wit b/components/wit/deps/wasi-io-0.2.6/package.wit similarity index 98% rename from components/wit/deps/wasi-io-0.2.8/package.wit rename to components/wit/deps/wasi-io-0.2.6/package.wit index 19fd428..c66abac 100644 --- a/components/wit/deps/wasi-io-0.2.8/package.wit +++ b/components/wit/deps/wasi-io-0.2.6/package.wit @@ -1,4 +1,4 @@ -package wasi:io@0.2.8; +package wasi:io@0.2.6; interface poll { resource pollable { diff --git a/components/wit/deps/wasi-random-0.2.8/package.wit b/components/wit/deps/wasi-random-0.2.6/package.wit similarity index 79% rename from components/wit/deps/wasi-random-0.2.8/package.wit rename to components/wit/deps/wasi-random-0.2.6/package.wit index 342c0dc..dfb249c 100644 --- a/components/wit/deps/wasi-random-0.2.8/package.wit +++ b/components/wit/deps/wasi-random-0.2.6/package.wit @@ -1,4 +1,4 @@ -package wasi:random@0.2.8; +package wasi:random@0.2.6; interface random { get-random-bytes: func(len: u64) -> list; diff --git a/components/wit/rest-client.wit b/components/wit/rest-client.wit index eb63daf..fdf40ea 100644 --- a/components/wit/rest-client.wit +++ b/components/wit/rest-client.wit @@ -14,5 +14,5 @@ interface rest-client { world rest-client-world { export rest-client; - import wasi:http/outgoing-handler@0.2.8; + import wasi:http/outgoing-handler@0.2.6; } diff --git a/components/wkg.lock b/components/wkg.lock index 1fb2298..5cdf7f0 100644 --- a/components/wkg.lock +++ b/components/wkg.lock @@ -7,9 +7,9 @@ name = "wasi:clocks" registry = "wasi.dev" [[packages.versions]] -requirement = "=0.2.8" -version = "0.2.8" -digest = "sha256:d47fd7df9c3f26ef5f86e3309a58f850db3ac0032b28ec285d6129c6a8f4a684" +requirement = "=0.2.6" +version = "0.2.6" +digest = "sha256:569984cc45d3f5a362a3b2897aabbaa3cc4184a6113bfcbbf03c1bd7fc20338c" [[packages]] name = "wasi:config" @@ -25,9 +25,9 @@ name = "wasi:http" registry = "wasi.dev" [[packages.versions]] -requirement = "=0.2.8" -version = "0.2.8" -digest = "sha256:efac1616dceaa5a7d0423a3732b0addf74013974ae90feeb1081555479dc5500" +requirement = "=0.2.6" +version = "0.2.6" +digest = "sha256:26a636620af0485dfcfc9a0563a0606564eedcf3fcabda031ab4d4ec0e505ff1" [[packages]] name = "wasi:logging"