From d9b692e6c024d8575ec8f39110446a49287e06e3 Mon Sep 17 00:00:00 2001 From: Yosh Date: Thu, 3 Oct 2024 20:57:43 +0200 Subject: [PATCH] Update to v0.2.2 --- .github/workflows/main.yml | 4 +- imports.md | 46 +-- proxy.md | 266 +++++++++--------- wit-0.3.0-draft/deps/cli/command.wit | 2 +- wit-0.3.0-draft/deps/cli/imports.wit | 12 +- wit-0.3.0-draft/deps/cli/stdio.wit | 6 +- .../deps/clocks/monotonic-clock.wit | 4 +- wit-0.3.0-draft/deps/clocks/timezone.wit | 2 +- wit-0.3.0-draft/deps/clocks/wall-clock.wit | 2 +- wit-0.3.0-draft/deps/clocks/world.wit | 2 +- wit-0.3.0-draft/deps/filesystem/preopens.wit | 2 +- wit-0.3.0-draft/deps/filesystem/types.wit | 6 +- wit-0.3.0-draft/deps/filesystem/world.wit | 2 +- wit-0.3.0-draft/deps/io/error.wit | 2 +- wit-0.3.0-draft/deps/io/poll.wit | 2 +- wit-0.3.0-draft/deps/io/streams.wit | 2 +- wit-0.3.0-draft/deps/io/world.wit | 2 +- wit-0.3.0-draft/deps/random/insecure-seed.wit | 2 +- wit-0.3.0-draft/deps/random/insecure.wit | 2 +- wit-0.3.0-draft/deps/random/random.wit | 2 +- wit-0.3.0-draft/deps/random/world.wit | 2 +- .../deps/sockets/ip-name-lookup.wit | 2 +- wit-0.3.0-draft/deps/sockets/tcp.wit | 6 +- wit-0.3.0-draft/deps/sockets/udp.wit | 2 +- wit-0.3.0-draft/deps/sockets/world.wit | 2 +- wit-0.3.0-draft/proxy.wit | 10 +- wit-0.3.0-draft/types.wit | 4 +- wit/deps.lock | 24 +- wit/deps/cli/command.wit | 2 +- wit/deps/cli/imports.wit | 12 +- wit/deps/cli/stdio.wit | 6 +- wit/deps/clocks/monotonic-clock.wit | 4 +- wit/deps/clocks/timezone.wit | 2 +- wit/deps/clocks/wall-clock.wit | 2 +- wit/deps/clocks/world.wit | 2 +- wit/deps/filesystem/preopens.wit | 2 +- wit/deps/filesystem/types.wit | 12 +- wit/deps/filesystem/world.wit | 2 +- wit/deps/io/error.wit | 2 +- wit/deps/io/poll.wit | 2 +- wit/deps/io/streams.wit | 6 +- wit/deps/io/world.wit | 2 +- wit/deps/random/insecure-seed.wit | 2 +- wit/deps/random/insecure.wit | 2 +- wit/deps/random/random.wit | 2 +- wit/deps/random/world.wit | 2 +- wit/deps/sockets/ip-name-lookup.wit | 4 +- wit/deps/sockets/network.wit | 16 ++ wit/deps/sockets/tcp.wit | 8 +- wit/deps/sockets/udp.wit | 8 +- wit/deps/sockets/world.wit | 2 +- wit/proxy.wit | 14 +- wit/types.wit | 8 +- 53 files changed, 283 insertions(+), 265 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e5ad565..d7a090b 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -18,6 +18,6 @@ jobs: ./wit-deps lock --check - uses: WebAssembly/wit-abi-up-to-date@v22 with: - wasm-tools: '1.215.0' - wit-bindgen: '0.30.0' + wasm-tools: '1.218.0' + wit-bindgen: '0.33.0' worlds: 'imports proxy' diff --git a/imports.md b/imports.md index 6a3caf1..5b71ecc 100644 --- a/imports.md +++ b/imports.md @@ -4,21 +4,21 @@ It is intended to be included in other worlds.

-

Import interface wasi:io/poll@0.2.1

+

Import interface wasi:io/poll@0.2.2

A poll API intended to let users wait for I/O events on multiple handles at once.


@@ -71,7 +71,7 @@ being ready for I/O.

-

Import interface wasi:clocks/monotonic-clock@0.2.1

+

Import interface wasi:clocks/monotonic-clock@0.2.2

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 @@ -130,7 +130,7 @@ elapsed from the time this function is invoked.

-

Import interface wasi:clocks/wall-clock@0.2.1

+

Import interface wasi:clocks/wall-clock@0.2.2

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.

@@ -171,7 +171,7 @@ also known as Unix Time.
  • datetime
  • -

    Import interface wasi:random/random@0.2.1

    +

    Import interface wasi:random/random@0.2.2

    WASI Random is a random data API.

    It is intended to be portable at least between Unix-family platforms and Windows.

    @@ -204,7 +204,7 @@ represented as a u64.

    -

    Import interface wasi:io/error@0.2.1

    +

    Import interface wasi:io/error@0.2.2


    Types

    resource error

    @@ -237,7 +237,7 @@ hazard.

    -

    Import interface wasi:io/streams@0.2.1

    +

    Import interface wasi:io/streams@0.2.2

    WASI I/O is an I/O abstraction API which is currently focused on providing stream types.

    In the future, the component model is expected to add built-in stream types; @@ -258,6 +258,8 @@ when it does, they are expected to subsume this API.

    last-operation-failed: own<error>

    The last operation (a write or flush) failed before completion.

    More information is available in the error payload.

    +

    After this, the stream will be closed. All future operations return +stream-error::closed.

  • closed

    @@ -565,7 +567,7 @@ is ready for reading, before performing the splice.

    -

    Import interface wasi:cli/stdout@0.2.1

    +

    Import interface wasi:cli/stdout@0.2.2


    Types

    type output-stream

    @@ -578,7 +580,7 @@ is ready for reading, before performing the splice.

    -

    Import interface wasi:cli/stderr@0.2.1

    +

    Import interface wasi:cli/stderr@0.2.2


    Types

    type output-stream

    @@ -591,7 +593,7 @@ is ready for reading, before performing the splice.

    -

    Import interface wasi:cli/stdin@0.2.1

    +

    Import interface wasi:cli/stdin@0.2.2


    Types

    type input-stream

    @@ -604,7 +606,7 @@ is ready for reading, before performing the splice.

    -

    Import interface wasi:http/types@0.2.1

    +

    Import interface wasi:http/types@0.2.2

    This interface defines all of the types and methods for implementing HTTP Requests and Responses, both incoming and outgoing, as well as their headers, trailers, and bodies.

    @@ -1505,7 +1507,7 @@ but those will be reported by the incoming-body
  • option<result<result<own<incoming-response>, error-code>>>
  • -

    Import interface wasi:http/outgoing-handler@0.2.1

    +

    Import interface wasi:http/outgoing-handler@0.2.2

    This interface defines a handler of outgoing HTTP Requests. It should be imported by components which wish to make HTTP Requests.


    diff --git a/proxy.md b/proxy.md index b0f72e2..ceb59c0 100644 --- a/proxy.md +++ b/proxy.md @@ -6,26 +6,26 @@ outgoing HTTP requests.

    -

    Import interface wasi:io/poll@0.2.1

    +

    Import interface wasi:io/poll@0.2.2

    A poll API intended to let users wait for I/O events on multiple handles at once.


    @@ -78,7 +78,7 @@ being ready for I/O.

    -

    Import interface wasi:clocks/monotonic-clock@0.2.1

    +

    Import interface wasi:clocks/monotonic-clock@0.2.2

    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 @@ -137,7 +137,81 @@ elapsed from the time this function is invoked.

    -

    Import interface wasi:io/error@0.2.1

    +

    Import interface wasi:clocks/wall-clock@0.2.2

    +

    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.

    +
    +

    Types

    +

    record datetime

    +

    A time and date in seconds plus nanoseconds.

    +
    Record Fields
    + +
    +

    Functions

    +

    now: func

    +

    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.

    +
    Return values
    + +

    resolution: func

    +

    Query the resolution of the clock.

    +

    The nanoseconds field of the output is always less than 1000000000.

    +
    Return values
    + +

    Import interface wasi:random/random@0.2.2

    +

    WASI Random is a random data API.

    +

    It is intended to be portable at least between Unix-family platforms and +Windows.

    +
    +

    Functions

    +

    get-random-bytes: func

    +

    Return len cryptographically-secure random or pseudo-random bytes.

    +

    This function must produce data at least as cryptographically secure and +fast as an adequately seeded cryptographically-secure pseudo-random +number generator (CSPRNG). It must not block, from the perspective of +the calling program, under any circumstances, including on the first +request and on requests for numbers of bytes. The returned data must +always be unpredictable.

    +

    This function must always return fresh data. Deterministic environments +must omit this function, rather than implementing it with deterministic +data.

    +
    Params
    + +
    Return values
    + +

    get-random-u64: func

    +

    Return a cryptographically-secure random or pseudo-random u64 value.

    +

    This function returns the same type of data as get-random-bytes, +represented as a u64.

    +
    Return values
    + +

    Import interface wasi:io/error@0.2.2


    Types

    resource error

    @@ -170,7 +244,7 @@ hazard.

    -

    Import interface wasi:io/streams@0.2.1

    +

    Import interface wasi:io/streams@0.2.2

    WASI I/O is an I/O abstraction API which is currently focused on providing stream types.

    In the future, the component model is expected to add built-in stream types; @@ -191,6 +265,8 @@ when it does, they are expected to subsume this API.

    last-operation-failed: own<error>

    The last operation (a write or flush) failed before completion.

    More information is available in the error payload.

    +

    After this, the stream will be closed. All future operations return +stream-error::closed.

  • closed

    @@ -498,7 +574,46 @@ is ready for reading, before performing the splice.

    -

    Import interface wasi:http/types@0.2.1

    +

    Import interface wasi:cli/stdout@0.2.2

    +
    +

    Types

    +

    type output-stream

    +

    output-stream

    +

    +---- +

    Functions

    +

    get-stdout: func

    +
    Return values
    + +

    Import interface wasi:cli/stderr@0.2.2

    +
    +

    Types

    +

    type output-stream

    +

    output-stream

    +

    +---- +

    Functions

    +

    get-stderr: func

    +
    Return values
    + +

    Import interface wasi:cli/stdin@0.2.2

    +
    +

    Types

    +

    type input-stream

    +

    input-stream

    +

    +---- +

    Functions

    +

    get-stdin: func

    +
    Return values
    + +

    Import interface wasi:http/types@0.2.2

    This interface defines all of the types and methods for implementing HTTP Requests and Responses, both incoming and outgoing, as well as their headers, trailers, and bodies.

    @@ -1399,120 +1514,7 @@ but those will be reported by the incoming-body
  • option<result<result<own<incoming-response>, error-code>>>
  • -

    Import interface wasi:clocks/wall-clock@0.2.1

    -

    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.

    -
    -

    Types

    -

    record datetime

    -

    A time and date in seconds plus nanoseconds.

    -
    Record Fields
    -
      -
    • seconds: u64
    • -
    • nanoseconds: u32
    • -
    -
    -

    Functions

    -

    now: func

    -

    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.

    -
    Return values
    - -

    resolution: func

    -

    Query the resolution of the clock.

    -

    The nanoseconds field of the output is always less than 1000000000.

    -
    Return values
    - -

    Import interface wasi:random/random@0.2.1

    -

    WASI Random is a random data API.

    -

    It is intended to be portable at least between Unix-family platforms and -Windows.

    -
    -

    Functions

    -

    get-random-bytes: func

    -

    Return len cryptographically-secure random or pseudo-random bytes.

    -

    This function must produce data at least as cryptographically secure and -fast as an adequately seeded cryptographically-secure pseudo-random -number generator (CSPRNG). It must not block, from the perspective of -the calling program, under any circumstances, including on the first -request and on requests for numbers of bytes. The returned data must -always be unpredictable.

    -

    This function must always return fresh data. Deterministic environments -must omit this function, rather than implementing it with deterministic -data.

    -
    Params
    -
      -
    • len: u64
    • -
    -
    Return values
    -
      -
    • list<u8>
    • -
    -

    get-random-u64: func

    -

    Return a cryptographically-secure random or pseudo-random u64 value.

    -

    This function returns the same type of data as get-random-bytes, -represented as a u64.

    -
    Return values
    -
      -
    • u64
    • -
    -

    Import interface wasi:cli/stdout@0.2.1

    -
    -

    Types

    -

    type output-stream

    -

    output-stream

    -

    ----- -

    Functions

    -

    get-stdout: func

    -
    Return values
    - -

    Import interface wasi:cli/stderr@0.2.1

    -
    -

    Types

    -

    type output-stream

    -

    output-stream

    -

    ----- -

    Functions

    -

    get-stderr: func

    -
    Return values
    - -

    Import interface wasi:cli/stdin@0.2.1

    -
    -

    Types

    -

    type input-stream

    -

    input-stream

    -

    ----- -

    Functions

    -

    get-stdin: func

    -
    Return values
    - -

    Import interface wasi:http/outgoing-handler@0.2.1

    +

    Import interface wasi:http/outgoing-handler@0.2.2

    This interface defines a handler of outgoing HTTP Requests. It should be imported by components which wish to make HTTP Requests.


    @@ -1549,7 +1551,7 @@ through the future-incoming-response
  • result<own<future-incoming-response>, error-code>
  • -

    Export interface wasi:http/incoming-handler@0.2.1

    +

    Export interface wasi:http/incoming-handler@0.2.2


    Types

    type incoming-request

    diff --git a/wit-0.3.0-draft/deps/cli/command.wit b/wit-0.3.0-draft/deps/cli/command.wit index dc064a3..cc7a352 100644 --- a/wit-0.3.0-draft/deps/cli/command.wit +++ b/wit-0.3.0-draft/deps/cli/command.wit @@ -1,4 +1,4 @@ -package wasi:cli@0.2.1; +package wasi:cli@0.2.2; @since(version = 0.2.0) world command { diff --git a/wit-0.3.0-draft/deps/cli/imports.wit b/wit-0.3.0-draft/deps/cli/imports.wit index b8339d3..ebd7ba1 100644 --- a/wit-0.3.0-draft/deps/cli/imports.wit +++ b/wit-0.3.0-draft/deps/cli/imports.wit @@ -1,17 +1,17 @@ -package wasi:cli@0.2.1; +package wasi:cli@0.2.2; @since(version = 0.2.0) world imports { @since(version = 0.2.0) - include wasi:clocks/imports@0.2.1; + include wasi:clocks/imports@0.2.2; @since(version = 0.2.0) - include wasi:filesystem/imports@0.2.1; + include wasi:filesystem/imports@0.2.2; @since(version = 0.2.0) - include wasi:sockets/imports@0.2.1; + include wasi:sockets/imports@0.2.2; @since(version = 0.2.0) - include wasi:random/imports@0.2.1; + include wasi:random/imports@0.2.2; @since(version = 0.2.0) - include wasi:io/imports@0.2.1; + include wasi:io/imports@0.2.2; @since(version = 0.2.0) import environment; diff --git a/wit-0.3.0-draft/deps/cli/stdio.wit b/wit-0.3.0-draft/deps/cli/stdio.wit index d1d26eb..860313e 100644 --- a/wit-0.3.0-draft/deps/cli/stdio.wit +++ b/wit-0.3.0-draft/deps/cli/stdio.wit @@ -1,7 +1,7 @@ @since(version = 0.2.0) interface stdin { @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{input-stream}; + use wasi:io/streams@0.2.2.{input-stream}; @since(version = 0.2.0) get-stdin: func() -> input-stream; @@ -10,7 +10,7 @@ interface stdin { @since(version = 0.2.0) interface stdout { @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{output-stream}; + use wasi:io/streams@0.2.2.{output-stream}; @since(version = 0.2.0) get-stdout: func() -> output-stream; @@ -19,7 +19,7 @@ interface stdout { @since(version = 0.2.0) interface stderr { @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{output-stream}; + use wasi:io/streams@0.2.2.{output-stream}; @since(version = 0.2.0) get-stderr: func() -> output-stream; diff --git a/wit-0.3.0-draft/deps/clocks/monotonic-clock.wit b/wit-0.3.0-draft/deps/clocks/monotonic-clock.wit index 3c24840..233cace 100644 --- a/wit-0.3.0-draft/deps/clocks/monotonic-clock.wit +++ b/wit-0.3.0-draft/deps/clocks/monotonic-clock.wit @@ -1,4 +1,4 @@ -package wasi:clocks@0.2.1; +package wasi:clocks@0.2.2; /// WASI Monotonic Clock is a clock API intended to let users measure elapsed /// time. /// @@ -10,7 +10,7 @@ package wasi:clocks@0.2.1; @since(version = 0.2.0) interface monotonic-clock { @since(version = 0.2.0) - use wasi:io/poll@0.2.1.{pollable}; + use wasi:io/poll@0.2.2.{pollable}; /// An instant in time, in nanoseconds. An instant is relative to an /// unspecified initial value, and can only be compared to instances from diff --git a/wit-0.3.0-draft/deps/clocks/timezone.wit b/wit-0.3.0-draft/deps/clocks/timezone.wit index 212da66..349fb57 100644 --- a/wit-0.3.0-draft/deps/clocks/timezone.wit +++ b/wit-0.3.0-draft/deps/clocks/timezone.wit @@ -1,4 +1,4 @@ -package wasi:clocks@0.2.1; +package wasi:clocks@0.2.2; @unstable(feature = clocks-timezone) interface timezone { diff --git a/wit-0.3.0-draft/deps/clocks/wall-clock.wit b/wit-0.3.0-draft/deps/clocks/wall-clock.wit index 6be069a..ec05a1f 100644 --- a/wit-0.3.0-draft/deps/clocks/wall-clock.wit +++ b/wit-0.3.0-draft/deps/clocks/wall-clock.wit @@ -1,4 +1,4 @@ -package wasi:clocks@0.2.1; +package wasi:clocks@0.2.2; /// 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. diff --git a/wit-0.3.0-draft/deps/clocks/world.wit b/wit-0.3.0-draft/deps/clocks/world.wit index 9251ac6..e36802c 100644 --- a/wit-0.3.0-draft/deps/clocks/world.wit +++ b/wit-0.3.0-draft/deps/clocks/world.wit @@ -1,4 +1,4 @@ -package wasi:clocks@0.2.1; +package wasi:clocks@0.2.2; @since(version = 0.2.0) world imports { diff --git a/wit-0.3.0-draft/deps/filesystem/preopens.wit b/wit-0.3.0-draft/deps/filesystem/preopens.wit index ca2f726..410bec1 100644 --- a/wit-0.3.0-draft/deps/filesystem/preopens.wit +++ b/wit-0.3.0-draft/deps/filesystem/preopens.wit @@ -1,4 +1,4 @@ -package wasi:filesystem@0.2.1; +package wasi:filesystem@0.2.2; @since(version = 0.2.0) interface preopens { diff --git a/wit-0.3.0-draft/deps/filesystem/types.wit b/wit-0.3.0-draft/deps/filesystem/types.wit index db3d968..57dffb2 100644 --- a/wit-0.3.0-draft/deps/filesystem/types.wit +++ b/wit-0.3.0-draft/deps/filesystem/types.wit @@ -1,4 +1,4 @@ -package wasi:filesystem@0.2.1; +package wasi:filesystem@0.2.2; /// WASI filesystem is a filesystem API primarily intended to let users run WASI /// programs that access their files on their existing filesystems, without /// significant overhead. @@ -26,9 +26,9 @@ package wasi:filesystem@0.2.1; @since(version = 0.2.0) interface types { @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{input-stream, output-stream, error}; + use wasi:io/streams@0.2.2.{input-stream, output-stream, error}; @since(version = 0.2.0) - use wasi:clocks/wall-clock@0.2.1.{datetime}; + use wasi:clocks/wall-clock@0.2.2.{datetime}; /// File size or length of a region within a file. @since(version = 0.2.0) diff --git a/wit-0.3.0-draft/deps/filesystem/world.wit b/wit-0.3.0-draft/deps/filesystem/world.wit index af0146c..8064bd6 100644 --- a/wit-0.3.0-draft/deps/filesystem/world.wit +++ b/wit-0.3.0-draft/deps/filesystem/world.wit @@ -1,4 +1,4 @@ -package wasi:filesystem@0.2.1; +package wasi:filesystem@0.2.2; @since(version = 0.2.0) world imports { diff --git a/wit-0.3.0-draft/deps/io/error.wit b/wit-0.3.0-draft/deps/io/error.wit index 4ea29c4..717135f 100644 --- a/wit-0.3.0-draft/deps/io/error.wit +++ b/wit-0.3.0-draft/deps/io/error.wit @@ -1,4 +1,4 @@ -package wasi:io@0.2.1; +package wasi:io@0.2.2; @since(version = 0.2.0) interface error { diff --git a/wit-0.3.0-draft/deps/io/poll.wit b/wit-0.3.0-draft/deps/io/poll.wit index b25ac72..49c1c5e 100644 --- a/wit-0.3.0-draft/deps/io/poll.wit +++ b/wit-0.3.0-draft/deps/io/poll.wit @@ -1,4 +1,4 @@ -package wasi:io@0.2.1; +package wasi:io@0.2.2; /// A poll API intended to let users wait for I/O events on multiple handles /// at once. diff --git a/wit-0.3.0-draft/deps/io/streams.wit b/wit-0.3.0-draft/deps/io/streams.wit index b697e24..80437d6 100644 --- a/wit-0.3.0-draft/deps/io/streams.wit +++ b/wit-0.3.0-draft/deps/io/streams.wit @@ -1,4 +1,4 @@ -package wasi:io@0.2.1; +package wasi:io@0.2.2; /// WASI I/O is an I/O abstraction API which is currently focused on providing /// stream types. diff --git a/wit-0.3.0-draft/deps/io/world.wit b/wit-0.3.0-draft/deps/io/world.wit index 6405a4e..f7001cc 100644 --- a/wit-0.3.0-draft/deps/io/world.wit +++ b/wit-0.3.0-draft/deps/io/world.wit @@ -1,4 +1,4 @@ -package wasi:io@0.2.1; +package wasi:io@0.2.2; @since(version = 0.2.0) world imports { diff --git a/wit-0.3.0-draft/deps/random/insecure-seed.wit b/wit-0.3.0-draft/deps/random/insecure-seed.wit index 7e708dc..cdea716 100644 --- a/wit-0.3.0-draft/deps/random/insecure-seed.wit +++ b/wit-0.3.0-draft/deps/random/insecure-seed.wit @@ -1,4 +1,4 @@ -package wasi:random@0.2.1; +package wasi:random@0.2.2; /// The insecure-seed interface for seeding hash-map DoS resistance. /// /// It is intended to be portable at least between Unix-family platforms and diff --git a/wit-0.3.0-draft/deps/random/insecure.wit b/wit-0.3.0-draft/deps/random/insecure.wit index 3cdb53d..b71e858 100644 --- a/wit-0.3.0-draft/deps/random/insecure.wit +++ b/wit-0.3.0-draft/deps/random/insecure.wit @@ -1,4 +1,4 @@ -package wasi:random@0.2.1; +package wasi:random@0.2.2; /// The insecure interface for insecure pseudo-random numbers. /// /// It is intended to be portable at least between Unix-family platforms and diff --git a/wit-0.3.0-draft/deps/random/random.wit b/wit-0.3.0-draft/deps/random/random.wit index 2b5035d..0c57e8c 100644 --- a/wit-0.3.0-draft/deps/random/random.wit +++ b/wit-0.3.0-draft/deps/random/random.wit @@ -1,4 +1,4 @@ -package wasi:random@0.2.1; +package wasi:random@0.2.2; /// WASI Random is a random data API. /// /// It is intended to be portable at least between Unix-family platforms and diff --git a/wit-0.3.0-draft/deps/random/world.wit b/wit-0.3.0-draft/deps/random/world.wit index c615e96..16d68ac 100644 --- a/wit-0.3.0-draft/deps/random/world.wit +++ b/wit-0.3.0-draft/deps/random/world.wit @@ -1,4 +1,4 @@ -package wasi:random@0.2.1; +package wasi:random@0.2.2; @since(version = 0.2.0) world imports { diff --git a/wit-0.3.0-draft/deps/sockets/ip-name-lookup.wit b/wit-0.3.0-draft/deps/sockets/ip-name-lookup.wit index dc56f30..8d6dcec 100644 --- a/wit-0.3.0-draft/deps/sockets/ip-name-lookup.wit +++ b/wit-0.3.0-draft/deps/sockets/ip-name-lookup.wit @@ -1,7 +1,7 @@ @since(version = 0.2.0) interface ip-name-lookup { @since(version = 0.2.0) - use wasi:io/poll@0.2.1.{pollable}; + use wasi:io/poll@0.2.2.{pollable}; @since(version = 0.2.0) use network.{network, error-code, ip-address}; diff --git a/wit-0.3.0-draft/deps/sockets/tcp.wit b/wit-0.3.0-draft/deps/sockets/tcp.wit index bae5a29..91f421b 100644 --- a/wit-0.3.0-draft/deps/sockets/tcp.wit +++ b/wit-0.3.0-draft/deps/sockets/tcp.wit @@ -1,11 +1,11 @@ @since(version = 0.2.0) interface tcp { @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{input-stream, output-stream}; + use wasi:io/streams@0.2.2.{input-stream, output-stream}; @since(version = 0.2.0) - use wasi:io/poll@0.2.1.{pollable}; + use wasi:io/poll@0.2.2.{pollable}; @since(version = 0.2.0) - use wasi:clocks/monotonic-clock@0.2.1.{duration}; + use wasi:clocks/monotonic-clock@0.2.2.{duration}; @since(version = 0.2.0) use network.{network, error-code, ip-socket-address, ip-address-family}; diff --git a/wit-0.3.0-draft/deps/sockets/udp.wit b/wit-0.3.0-draft/deps/sockets/udp.wit index b289e49..328d916 100644 --- a/wit-0.3.0-draft/deps/sockets/udp.wit +++ b/wit-0.3.0-draft/deps/sockets/udp.wit @@ -1,7 +1,7 @@ @since(version = 0.2.0) interface udp { @since(version = 0.2.0) - use wasi:io/poll@0.2.1.{pollable}; + use wasi:io/poll@0.2.2.{pollable}; @since(version = 0.2.0) use network.{network, error-code, ip-socket-address, ip-address-family}; diff --git a/wit-0.3.0-draft/deps/sockets/world.wit b/wit-0.3.0-draft/deps/sockets/world.wit index a1d4267..6e349c7 100644 --- a/wit-0.3.0-draft/deps/sockets/world.wit +++ b/wit-0.3.0-draft/deps/sockets/world.wit @@ -1,4 +1,4 @@ -package wasi:sockets@0.2.1; +package wasi:sockets@0.2.2; @since(version = 0.2.0) world imports { diff --git a/wit-0.3.0-draft/proxy.wit b/wit-0.3.0-draft/proxy.wit index 6a83dc7..5342784 100644 --- a/wit-0.3.0-draft/proxy.wit +++ b/wit-0.3.0-draft/proxy.wit @@ -4,19 +4,19 @@ package wasi:http@0.3.0-draft; /// It is intended to be `include`d in other worlds. world imports { /// HTTP proxies have access to time and randomness. - include wasi:clocks/imports@0.2.1; - import wasi:random/random@0.2.1; + include wasi:clocks/imports@0.2.2; + import wasi:random/random@0.2.2; /// Proxies have standard output and error streams which are expected to /// terminate in a developer-facing console provided by the host. - import wasi:cli/stdout@0.2.1; - import wasi:cli/stderr@0.2.1; + import wasi:cli/stdout@0.2.2; + import wasi:cli/stderr@0.2.2; /// TODO: this is a temporary workaround until component tooling is able to /// gracefully handle the absence of stdin. Hosts must return an eof stream /// for this import, which is what wasi-libc + tooling will do automatically /// when this import is properly removed. - import wasi:cli/stdin@0.2.1; + import wasi:cli/stdin@0.2.2; /// This is the default handler to use when user code simply wants to make an /// HTTP request (e.g., via `fetch()`). diff --git a/wit-0.3.0-draft/types.wit b/wit-0.3.0-draft/types.wit index f702c15..e272ab0 100644 --- a/wit-0.3.0-draft/types.wit +++ b/wit-0.3.0-draft/types.wit @@ -1,8 +1,8 @@ /// This interface defines all of the types and methods for implementing HTTP /// Requests and Responses, as well as their headers, trailers, and bodies. interface types { - use wasi:clocks/monotonic-clock@0.2.1.{duration}; - use wasi:io/error@0.2.1.{error}; + use wasi:clocks/monotonic-clock@0.2.2.{duration}; + use wasi:io/error@0.2.2.{error}; /// This type corresponds to HTTP standard Methods. variant method { diff --git a/wit/deps.lock b/wit/deps.lock index a12064a..8d1257d 100644 --- a/wit/deps.lock +++ b/wit/deps.lock @@ -1,29 +1,29 @@ [cli] url = "https://github.com/WebAssembly/wasi-cli/archive/main.tar.gz" -sha256 = "1de50b8e6940e73110cda10b7f90ca87a8fea886f0fa36c748f96dc70671ee38" -sha512 = "bbb6cd3e7b4d3237b6af9bfbb2633ccd2c4ea2a4f37b8c033255c7e0c1cb037be7f22ec1f8ca792cc8ec1942199582943979e646b4b272b85dcff7654eac51d0" +sha256 = "052c438d7606115bcfbe43094c55764c3396acfc8e4c69a6f54f7abcf8ef7c8c" +sha512 = "cce72d006e639cacabbd01137af99029591403a9bf6db8475e87d82cd6f256fa2118f9d15d5d88a34cacfaeb8d472f21f0914b20c83f6da1771f763cad4e1379" [clocks] url = "https://github.com/WebAssembly/wasi-clocks/archive/main.tar.gz" -sha256 = "ea9d69ee803bc176e23e5268f5e24a2ac485dd1f62a0ab4c748e9d3f901f576f" -sha512 = "5efc22927c46cd56c41e5549ec775561c7fac2ea0d365abc0b55396d9475a7c9f984077a81f84a44a726f1c008fd2fadbffffa4fa53ecd5fbfd05afd379ab428" +sha256 = "c2da62619d1067646316e8592b583d77036d778e28b1154353e0825956b3d6aa" +sha512 = "4d409fc38b31646fc5de70160e81bd3fa67f9c99b4d24543b4fd40a922c7545739869521b8a997efb675d0816de8b001b6af7950e0cb0bc823d89b9f07b286c4" [filesystem] url = "https://github.com/WebAssembly/wasi-filesystem/archive/main.tar.gz" -sha256 = "cfe8c420e8b857de612ae2a3336680dae16b95c93c8ba3a6ff05b21210966740" -sha512 = "3c00c5544a58658e3e8025677091685286027fd49f37abf198c30b4e83b9e68f19723975aaa98794fba9f425ae9ef4f3dc0f5b9cf59203b5ecfaadf62b296f9a" +sha256 = "69e220ec22593f097c7f486dd9e4f95576ef7056d3d531a86a277654872997ba" +sha512 = "457c027aebd1430e924564b3bb2477bc163083cb1029105c1432cbdc165cdf3cce4ac62dbb8e43e3dec09e24a6b2029204212e2f0e3919137cb207165368e157" [io] url = "https://github.com/WebAssembly/wasi-io/archive/main.tar.gz" -sha256 = "2a74bd811adc46b5a0f19827ddbde89870e52b17615f4d0873f06fd977250caf" -sha512 = "94624f00c66e66203592cee820f80b1ba91ecdb71f682c154f25eaf71f8d8954197dcb64503bc21e72ed5e812af7eae876df47b7eb727b02db3a74a7ce0aefca" +sha256 = "6d8dbfaaaa685167c1829616dc7265f5f3cb776845879555612d56544f6d9bfc" +sha512 = "52219562c4183503169cd2947b8164e1c96974500a5adf15bbf382c5992a10a626cc89c3b319204aeda6698ce59cbca2c42f98f7fde296aa77b9db4b41154dbe" [random] url = "https://github.com/WebAssembly/wasi-random/archive/main.tar.gz" -sha256 = "9e2d5056186f81b2e7f96bc97d2babd0341840f6abb4f170449b70992f1b598f" -sha512 = "67bf41d8d5d4b7af084124ee85196585225785969059f59e2f9ddb77ac1a8095cfe811ae29d076aac817418fa01064d7b9fbc0233930bace680758eeb21e36f8" +sha256 = "b4bb285b1c51aac2f8911f6b44ba1587108a2b24f910fe4774414dc286678b66" +sha512 = "bc2ffca0ae48f54977a763a70fcfcd5f4fca6b7c530916352f98c59627cc3f5899e47b6308bd9848b8c72e14db57e254757d580010a3d56e6888dafce3dcb679" [sockets] url = "https://github.com/WebAssembly/wasi-sockets/archive/main.tar.gz" -sha256 = "4c361137a7e61e8b9a73da2a0899dd9ad1a0c2dfee7d310cf168704c57b7a07c" -sha512 = "348b4ef381f57aec23d48537df8b69ab8963587dcb056e94c4cd5657e217677a4ee2a545868a5c829d2334cc6b8b0a61d3e72797999f44d78553fbd3a73c5b8d" +sha256 = "f254783796170fdeac6756496cc6169903a88adeda7a5895265414bc63ba4d66" +sha512 = "3f68e874beb0ac9729d1738546a430f2f8b369eb510d3cd6dfcfc41427acb52a82701d73584b8ab637b8c3908c5d4f7a7d4806032cc5d375643fad0ebf84e053" diff --git a/wit/deps/cli/command.wit b/wit/deps/cli/command.wit index dc064a3..cc7a352 100644 --- a/wit/deps/cli/command.wit +++ b/wit/deps/cli/command.wit @@ -1,4 +1,4 @@ -package wasi:cli@0.2.1; +package wasi:cli@0.2.2; @since(version = 0.2.0) world command { diff --git a/wit/deps/cli/imports.wit b/wit/deps/cli/imports.wit index b8339d3..ebd7ba1 100644 --- a/wit/deps/cli/imports.wit +++ b/wit/deps/cli/imports.wit @@ -1,17 +1,17 @@ -package wasi:cli@0.2.1; +package wasi:cli@0.2.2; @since(version = 0.2.0) world imports { @since(version = 0.2.0) - include wasi:clocks/imports@0.2.1; + include wasi:clocks/imports@0.2.2; @since(version = 0.2.0) - include wasi:filesystem/imports@0.2.1; + include wasi:filesystem/imports@0.2.2; @since(version = 0.2.0) - include wasi:sockets/imports@0.2.1; + include wasi:sockets/imports@0.2.2; @since(version = 0.2.0) - include wasi:random/imports@0.2.1; + include wasi:random/imports@0.2.2; @since(version = 0.2.0) - include wasi:io/imports@0.2.1; + include wasi:io/imports@0.2.2; @since(version = 0.2.0) import environment; diff --git a/wit/deps/cli/stdio.wit b/wit/deps/cli/stdio.wit index d1d26eb..860313e 100644 --- a/wit/deps/cli/stdio.wit +++ b/wit/deps/cli/stdio.wit @@ -1,7 +1,7 @@ @since(version = 0.2.0) interface stdin { @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{input-stream}; + use wasi:io/streams@0.2.2.{input-stream}; @since(version = 0.2.0) get-stdin: func() -> input-stream; @@ -10,7 +10,7 @@ interface stdin { @since(version = 0.2.0) interface stdout { @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{output-stream}; + use wasi:io/streams@0.2.2.{output-stream}; @since(version = 0.2.0) get-stdout: func() -> output-stream; @@ -19,7 +19,7 @@ interface stdout { @since(version = 0.2.0) interface stderr { @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{output-stream}; + use wasi:io/streams@0.2.2.{output-stream}; @since(version = 0.2.0) get-stderr: func() -> output-stream; diff --git a/wit/deps/clocks/monotonic-clock.wit b/wit/deps/clocks/monotonic-clock.wit index 3c24840..233cace 100644 --- a/wit/deps/clocks/monotonic-clock.wit +++ b/wit/deps/clocks/monotonic-clock.wit @@ -1,4 +1,4 @@ -package wasi:clocks@0.2.1; +package wasi:clocks@0.2.2; /// WASI Monotonic Clock is a clock API intended to let users measure elapsed /// time. /// @@ -10,7 +10,7 @@ package wasi:clocks@0.2.1; @since(version = 0.2.0) interface monotonic-clock { @since(version = 0.2.0) - use wasi:io/poll@0.2.1.{pollable}; + use wasi:io/poll@0.2.2.{pollable}; /// An instant in time, in nanoseconds. An instant is relative to an /// unspecified initial value, and can only be compared to instances from diff --git a/wit/deps/clocks/timezone.wit b/wit/deps/clocks/timezone.wit index 212da66..349fb57 100644 --- a/wit/deps/clocks/timezone.wit +++ b/wit/deps/clocks/timezone.wit @@ -1,4 +1,4 @@ -package wasi:clocks@0.2.1; +package wasi:clocks@0.2.2; @unstable(feature = clocks-timezone) interface timezone { diff --git a/wit/deps/clocks/wall-clock.wit b/wit/deps/clocks/wall-clock.wit index 6be069a..ec05a1f 100644 --- a/wit/deps/clocks/wall-clock.wit +++ b/wit/deps/clocks/wall-clock.wit @@ -1,4 +1,4 @@ -package wasi:clocks@0.2.1; +package wasi:clocks@0.2.2; /// 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. diff --git a/wit/deps/clocks/world.wit b/wit/deps/clocks/world.wit index 9251ac6..e36802c 100644 --- a/wit/deps/clocks/world.wit +++ b/wit/deps/clocks/world.wit @@ -1,4 +1,4 @@ -package wasi:clocks@0.2.1; +package wasi:clocks@0.2.2; @since(version = 0.2.0) world imports { diff --git a/wit/deps/filesystem/preopens.wit b/wit/deps/filesystem/preopens.wit index ca2f726..410bec1 100644 --- a/wit/deps/filesystem/preopens.wit +++ b/wit/deps/filesystem/preopens.wit @@ -1,4 +1,4 @@ -package wasi:filesystem@0.2.1; +package wasi:filesystem@0.2.2; @since(version = 0.2.0) interface preopens { diff --git a/wit/deps/filesystem/types.wit b/wit/deps/filesystem/types.wit index db3d968..49e0a30 100644 --- a/wit/deps/filesystem/types.wit +++ b/wit/deps/filesystem/types.wit @@ -1,4 +1,4 @@ -package wasi:filesystem@0.2.1; +package wasi:filesystem@0.2.2; /// WASI filesystem is a filesystem API primarily intended to let users run WASI /// programs that access their files on their existing filesystems, without /// significant overhead. @@ -26,9 +26,9 @@ package wasi:filesystem@0.2.1; @since(version = 0.2.0) interface types { @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{input-stream, output-stream, error}; + use wasi:io/streams@0.2.2.{input-stream, output-stream, error}; @since(version = 0.2.0) - use wasi:clocks/wall-clock@0.2.1.{datetime}; + use wasi:clocks/wall-clock@0.2.2.{datetime}; /// File size or length of a region within a file. @since(version = 0.2.0) @@ -523,12 +523,6 @@ interface types { /// Open a file or directory. /// - /// The returned descriptor is not guaranteed to be the lowest-numbered - /// descriptor not currently open/ it is randomized to prevent applications - /// from depending on making assumptions about indexes, since this is - /// error-prone in multi-threaded contexts. The returned descriptor is - /// guaranteed to be less than 2**31. - /// /// If `flags` contains `descriptor-flags::mutate-directory`, and the base /// descriptor doesn't have `descriptor-flags::mutate-directory` set, /// `open-at` fails with `error-code::read-only`. diff --git a/wit/deps/filesystem/world.wit b/wit/deps/filesystem/world.wit index af0146c..8064bd6 100644 --- a/wit/deps/filesystem/world.wit +++ b/wit/deps/filesystem/world.wit @@ -1,4 +1,4 @@ -package wasi:filesystem@0.2.1; +package wasi:filesystem@0.2.2; @since(version = 0.2.0) world imports { diff --git a/wit/deps/io/error.wit b/wit/deps/io/error.wit index 4ea29c4..717135f 100644 --- a/wit/deps/io/error.wit +++ b/wit/deps/io/error.wit @@ -1,4 +1,4 @@ -package wasi:io@0.2.1; +package wasi:io@0.2.2; @since(version = 0.2.0) interface error { diff --git a/wit/deps/io/poll.wit b/wit/deps/io/poll.wit index b25ac72..49c1c5e 100644 --- a/wit/deps/io/poll.wit +++ b/wit/deps/io/poll.wit @@ -1,4 +1,4 @@ -package wasi:io@0.2.1; +package wasi:io@0.2.2; /// A poll API intended to let users wait for I/O events on multiple handles /// at once. diff --git a/wit/deps/io/streams.wit b/wit/deps/io/streams.wit index b697e24..330f709 100644 --- a/wit/deps/io/streams.wit +++ b/wit/deps/io/streams.wit @@ -1,4 +1,4 @@ -package wasi:io@0.2.1; +package wasi:io@0.2.2; /// WASI I/O is an I/O abstraction API which is currently focused on providing /// stream types. @@ -18,6 +18,9 @@ interface streams { /// The last operation (a write or flush) failed before completion. /// /// More information is available in the `error` payload. + /// + /// After this, the stream will be closed. All future operations return + /// `stream-error::closed`. last-operation-failed(error), /// The stream is closed: no more input will be accepted by the /// stream. A closed output-stream will return this error on all @@ -205,6 +208,7 @@ interface streams { /// The created `pollable` is a child resource of the `output-stream`. /// Implementations may trap if the `output-stream` is dropped before /// all derived `pollable`s created with this function are dropped. + @since(version = 0.2.0) subscribe: func() -> pollable; /// Write zeroes to a stream. diff --git a/wit/deps/io/world.wit b/wit/deps/io/world.wit index 6405a4e..f7001cc 100644 --- a/wit/deps/io/world.wit +++ b/wit/deps/io/world.wit @@ -1,4 +1,4 @@ -package wasi:io@0.2.1; +package wasi:io@0.2.2; @since(version = 0.2.0) world imports { diff --git a/wit/deps/random/insecure-seed.wit b/wit/deps/random/insecure-seed.wit index 7e708dc..cdea716 100644 --- a/wit/deps/random/insecure-seed.wit +++ b/wit/deps/random/insecure-seed.wit @@ -1,4 +1,4 @@ -package wasi:random@0.2.1; +package wasi:random@0.2.2; /// The insecure-seed interface for seeding hash-map DoS resistance. /// /// It is intended to be portable at least between Unix-family platforms and diff --git a/wit/deps/random/insecure.wit b/wit/deps/random/insecure.wit index 3cdb53d..b71e858 100644 --- a/wit/deps/random/insecure.wit +++ b/wit/deps/random/insecure.wit @@ -1,4 +1,4 @@ -package wasi:random@0.2.1; +package wasi:random@0.2.2; /// The insecure interface for insecure pseudo-random numbers. /// /// It is intended to be portable at least between Unix-family platforms and diff --git a/wit/deps/random/random.wit b/wit/deps/random/random.wit index 2b5035d..0c57e8c 100644 --- a/wit/deps/random/random.wit +++ b/wit/deps/random/random.wit @@ -1,4 +1,4 @@ -package wasi:random@0.2.1; +package wasi:random@0.2.2; /// WASI Random is a random data API. /// /// It is intended to be portable at least between Unix-family platforms and diff --git a/wit/deps/random/world.wit b/wit/deps/random/world.wit index c615e96..16d68ac 100644 --- a/wit/deps/random/world.wit +++ b/wit/deps/random/world.wit @@ -1,4 +1,4 @@ -package wasi:random@0.2.1; +package wasi:random@0.2.2; @since(version = 0.2.0) world imports { diff --git a/wit/deps/sockets/ip-name-lookup.wit b/wit/deps/sockets/ip-name-lookup.wit index dc56f30..d3ab88a 100644 --- a/wit/deps/sockets/ip-name-lookup.wit +++ b/wit/deps/sockets/ip-name-lookup.wit @@ -1,7 +1,7 @@ @since(version = 0.2.0) interface ip-name-lookup { @since(version = 0.2.0) - use wasi:io/poll@0.2.1.{pollable}; + use wasi:io/poll@0.2.2.{pollable}; @since(version = 0.2.0) use network.{network, error-code, ip-address}; @@ -48,7 +48,7 @@ interface ip-name-lookup { /// Create a `pollable` which will resolve once the stream is ready for I/O. /// - /// Note: this function is here for WASI Preview2 only. + /// Note: this function is here for WASI 0.2 only. /// It's planned to be removed when `future` is natively supported in Preview3. @since(version = 0.2.0) subscribe: func() -> pollable; diff --git a/wit/deps/sockets/network.wit b/wit/deps/sockets/network.wit index 8c13b34..7f2d86a 100644 --- a/wit/deps/sockets/network.wit +++ b/wit/deps/sockets/network.wit @@ -1,5 +1,8 @@ @since(version = 0.2.0) interface network { + @unstable(feature = network-error-code) + use wasi:io/error@0.2.2.{error}; + /// An opaque resource that represents access to (a subset of) the network. /// This enables context-based security for networking. /// There is no need for this to map 1:1 to a physical network interface. @@ -105,6 +108,19 @@ interface network { permanent-resolver-failure, } + /// Attempts to extract a network-related `error-code` from the stream + /// `error` provided. + /// + /// Stream operations which return `stream-error::last-operation-failed` + /// have a payload with more information about the operation that failed. + /// This payload can be passed through to this function to see if there's + /// network-related information about the error to return. + /// + /// Note that this function is fallible because not all stream-related + /// errors are network-related errors. + @unstable(feature = network-error-code) + network-error-code: func(err: borrow) -> option; + @since(version = 0.2.0) enum ip-address-family { /// Similar to `AF_INET` in POSIX. diff --git a/wit/deps/sockets/tcp.wit b/wit/deps/sockets/tcp.wit index bae5a29..728822d 100644 --- a/wit/deps/sockets/tcp.wit +++ b/wit/deps/sockets/tcp.wit @@ -1,11 +1,11 @@ @since(version = 0.2.0) interface tcp { @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{input-stream, output-stream}; + use wasi:io/streams@0.2.2.{input-stream, output-stream}; @since(version = 0.2.0) - use wasi:io/poll@0.2.1.{pollable}; + use wasi:io/poll@0.2.2.{pollable}; @since(version = 0.2.0) - use wasi:clocks/monotonic-clock@0.2.1.{duration}; + use wasi:clocks/monotonic-clock@0.2.2.{duration}; @since(version = 0.2.0) use network.{network, error-code, ip-socket-address, ip-address-family}; @@ -353,7 +353,7 @@ interface tcp { /// See /// for more information. /// - /// Note: this function is here for WASI Preview2 only. + /// Note: this function is here for WASI 0.2 only. /// It's planned to be removed when `future` is natively supported in Preview3. @since(version = 0.2.0) subscribe: func() -> pollable; diff --git a/wit/deps/sockets/udp.wit b/wit/deps/sockets/udp.wit index b289e49..d8acb2d 100644 --- a/wit/deps/sockets/udp.wit +++ b/wit/deps/sockets/udp.wit @@ -1,7 +1,7 @@ @since(version = 0.2.0) interface udp { @since(version = 0.2.0) - use wasi:io/poll@0.2.1.{pollable}; + use wasi:io/poll@0.2.2.{pollable}; @since(version = 0.2.0) use network.{network, error-code, ip-socket-address, ip-address-family}; @@ -184,7 +184,7 @@ interface udp { /// Create a `pollable` which will resolve once the socket is ready for I/O. /// - /// Note: this function is here for WASI Preview2 only. + /// Note: this function is here for WASI 0.2 only. /// It's planned to be removed when `future` is natively supported in Preview3. @since(version = 0.2.0) subscribe: func() -> pollable; @@ -220,7 +220,7 @@ interface udp { /// Create a `pollable` which will resolve once the stream is ready to receive again. /// - /// Note: this function is here for WASI Preview2 only. + /// Note: this function is here for WASI 0.2 only. /// It's planned to be removed when `future` is natively supported in Preview3. @since(version = 0.2.0) subscribe: func() -> pollable; @@ -280,7 +280,7 @@ interface udp { /// Create a `pollable` which will resolve once the stream is ready to send again. /// - /// Note: this function is here for WASI Preview2 only. + /// Note: this function is here for WASI 0.2 only. /// It's planned to be removed when `future` is natively supported in Preview3. @since(version = 0.2.0) subscribe: func() -> pollable; diff --git a/wit/deps/sockets/world.wit b/wit/deps/sockets/world.wit index a1d4267..6e349c7 100644 --- a/wit/deps/sockets/world.wit +++ b/wit/deps/sockets/world.wit @@ -1,4 +1,4 @@ -package wasi:sockets@0.2.1; +package wasi:sockets@0.2.2; @since(version = 0.2.0) world imports { diff --git a/wit/proxy.wit b/wit/proxy.wit index 415d2ee..fadb89a 100644 --- a/wit/proxy.wit +++ b/wit/proxy.wit @@ -1,4 +1,4 @@ -package wasi:http@0.2.1; +package wasi:http@0.2.2; /// The `wasi:http/imports` world imports all the APIs for HTTP proxies. /// It is intended to be `include`d in other worlds. @@ -6,25 +6,25 @@ package wasi:http@0.2.1; world imports { /// HTTP proxies have access to time and randomness. @since(version = 0.2.0) - import wasi:clocks/monotonic-clock@0.2.1; + import wasi:clocks/monotonic-clock@0.2.2; @since(version = 0.2.0) - import wasi:clocks/wall-clock@0.2.1; + import wasi:clocks/wall-clock@0.2.2; @since(version = 0.2.0) - import wasi:random/random@0.2.1; + import wasi:random/random@0.2.2; /// Proxies have standard output and error streams which are expected to /// terminate in a developer-facing console provided by the host. @since(version = 0.2.0) - import wasi:cli/stdout@0.2.1; + import wasi:cli/stdout@0.2.2; @since(version = 0.2.0) - import wasi:cli/stderr@0.2.1; + import wasi:cli/stderr@0.2.2; /// TODO: this is a temporary workaround until component tooling is able to /// gracefully handle the absence of stdin. Hosts must return an eof stream /// for this import, which is what wasi-libc + tooling will do automatically /// when this import is properly removed. @since(version = 0.2.0) - import wasi:cli/stdin@0.2.1; + import wasi:cli/stdin@0.2.2; /// This is the default handler to use when user code simply wants to make an /// HTTP request (e.g., via `fetch()`). diff --git a/wit/types.wit b/wit/types.wit index 30b3642..40ee770 100644 --- a/wit/types.wit +++ b/wit/types.wit @@ -4,13 +4,13 @@ @since(version = 0.2.0) interface types { @since(version = 0.2.0) - use wasi:clocks/monotonic-clock@0.2.1.{duration}; + use wasi:clocks/monotonic-clock@0.2.2.{duration}; @since(version = 0.2.0) - use wasi:io/streams@0.2.1.{input-stream, output-stream}; + use wasi:io/streams@0.2.2.{input-stream, output-stream}; @since(version = 0.2.0) - use wasi:io/error@0.2.1.{error as io-error}; + use wasi:io/error@0.2.2.{error as io-error}; @since(version = 0.2.0) - use wasi:io/poll@0.2.1.{pollable}; + use wasi:io/poll@0.2.2.{pollable}; /// This type corresponds to HTTP standard Methods. @since(version = 0.2.0)