Skip to content

incoming-request-* should return Result<foo> #820

Closed

Description

@brendandburns

Currently the incoming-request-{authority, path, scheme, etc} family of methods currently do not have a way to indicate that an error occurred when fetching the value (e.g. if the request id is unknown)

Activity

  1. pchickey commented on Mar 22, 2023

    @pchickey
    Contributor

    Is the request id unknown the only possible error here? If so, we can make these fallible for now, but once we have resources, the request will be guaranteed to be valid when it crosses a component boundary (if a bad table index is passed to the cabi, the runtime will trap), so we'll want to note that the result is temporary until resources land

  2. lukewagner commented on Mar 27, 2023

    @lukewagner
    Member

    (sorry for slow reply; back now) As is, the CABI specifies traps (as if executing unreachable) in various cases that suggest fundamental toolchain bugs or corruption on the part of the guest (things like offset/length out of bounds, invalid UTF-8, etc). Once resources/handles are implemented, the CABI will similarly specify a trap when the i32 handle index is out-of-bounds w.r.t the associated table, so I think we should similarly say that is what happens in the current pre-handle state of the world.

  3. added
    S-inactiveStatus: no discussion in over a year. Records silence during triage; not a proposal to close.
    on Aug 20, 2026
  4. sw17ch commented on Oct 8, 2026

    @sw17ch

    The WASI HTTP champions looked at this in triage. We belive these are resolved by the current state of the specification.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P-httpProposal: wasi-httpS-inactiveStatus: no discussion in over a year. Records silence during triage; not a proposal to close.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions