Skip to content

wasi-sockets: Simplify ip name lookup interface - #7483

Merged
alexcrichton merged 4 commits into
bytecodealliance:mainfrom
badeend:simplify-ip-name-lookup
Nov 6, 2023
Merged

alexcrichton merged 4 commits into
bytecodealliance:mainfrom
badeend:simplify-ip-name-lookup

Conversation

@badeend

@badeend badeend commented Nov 5, 2023

Copy link
Copy Markdown
Member

Simplify ip name lookup interface:

  • Remove the non-essential parameters for now. Post-preview2 these can be reevaluated again.
  • Lift the restriction against parsing IP addresses. Before, implementations still needed to parse IP addresses to decide whether or not to return an error.

Related: #7013


FYI, the test includes a lookup to münchen.de to test for internationalized domain names support. But it might be a bit weird to query this random, non-affiliated DNS server in the wasmtime CI. I tried looking for a standard testdomain (like example.com), but couldn't find any.

@badeend
badeend requested a review from a team as a code owner November 5, 2023 12:51
@badeend
badeend requested review from fitzgen and removed request for a team November 5, 2023 12:51
@badeend
badeend force-pushed the simplify-ip-name-lookup branch from ce94830 to 8335773 Compare November 5, 2023 12:57
- Remove the non-essential parameters
- Lift the restriction against parsing IP addresses. Implementations would still have to parse IP addresses to decide whether or not to return an error
@badeend
badeend force-pushed the simplify-ip-name-lookup branch from 8335773 to 64944f5 Compare November 5, 2023 13:11
@github-actions github-actions Bot added the wasi Issues pertaining to WASI label Nov 5, 2023

@alexcrichton alexcrichton left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

We can add some code to the test later on if the resolution fails to try to cover up anything spurious that might show up

@alexcrichton
alexcrichton added this pull request to the merge queue Nov 5, 2023
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Nov 5, 2023
@badeend

badeend commented Nov 6, 2023

Copy link
Copy Markdown
Member Author

I've resolved the conflicts

@alexcrichton
alexcrichton added this pull request to the merge queue Nov 6, 2023
Merged via the queue into bytecodealliance:main with commit c91566f Nov 6, 2023
alexcrichton pushed a commit to alexcrichton/wasmtime that referenced this pull request Nov 7, 2023
* Refactor ip_name_lookup test

* Update ip-name-lookup::resolve-addresses

- Remove the non-essential parameters
- Lift the restriction against parsing IP addresses. Implementations would still have to parse IP addresses to decide whether or not to return an error

* Deduplicate to_canonical
alexcrichton added a commit that referenced this pull request Nov 7, 2023
* Update wasm-tools dependencies (#7488)

Pull in bytecodealliance/wasm-tools#1277 to switch the defaults for some
WIT behaviors:

* Semicolons are now required by default in WIT files
* Wasm-encoded WIT packages now use the "new" format by default.

WIT files without semicolons can still be parsed with
`WIT_REQUIRE_SEMICOLONS=0`. The "old" format for wasm-encoded WIT
packages can be emitted via `WIT_COMPONENT_ENCODING_V2=0`. Note that for
wasm-encoded WIT packages both the old and the new format can be decoded
irregardless of env vars.

* wasi-sockets: Sync up UDP implementation & tests with TCP (#7423)

* Refactor & move utilities. So that UDP can use them too.

* Minor tweak in error code while connecting

* Refactor: move portability workarounds out of the TCP implementation.

* Sync up UDP implementation and tests
based on the existing TCP implementation & tests.

* Make test less flaky in CI.

* wasi-sockets: Simplify ip name lookup interface (#7483)

* Refactor ip_name_lookup test

* Update ip-name-lookup::resolve-addresses

- Remove the non-essential parameters
- Lift the restriction against parsing IP addresses. Implementations would still have to parse IP addresses to decide whether or not to return an error

* Deduplicate to_canonical

* Add release notes for 15.0.0 (#7487)

---------

Co-authored-by: Dave Bakker <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

wasi Issues pertaining to WASI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants