Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(transport): Add WebTransport for WASM environments #4065

Closed
wants to merge 9 commits into from

Conversation

thomaseizinger
Copy link
Contributor

@thomaseizinger thomaseizinger commented Jun 12, 2023

Description

This PR implements Transport for WebTransport for browsers by using web-sys.

Related: #3846.
Depends-On: #4064.

Co-authored-by: Yiannis Marangos [email protected]

Notes & open questions

This is exactly #4015 but pushed to a branch of this repository so we can stack them.

Change checklist

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • A changelog entry has been made in the appropriate crates

mxinden and others added 8 commits June 8, 2023 05:51
This removes multiple duplicate dependencies from our lockfile. Unsure why dependabot hasn't done these yet.

Pull-Request: #4044.
- Adding conditional `cfg` in `keypair.rs` imports.
- Adding `#[allow(unused_variables)]` on the top of the `sign` function.

Pull-Request: #4047.
This extends `ToSwarm` to add `ToSwarm::ListenOn` and `ToSwarm::RemoveListener`, which allows creating and removing listeners from a `NetworkBehaviour`.

Resolves #3291.

Pull-Request: #3292.
> Observed addresses (aka. external address candidates) of the local node, reported by a remote node
> via `libp2p-identify`, are no longer automatically considered confirmed external addresses, in
> other words they are no longer trusted by default. Instead users need to confirm the reported
> observed address either manually, or by using `libp2p-autonat`. In trusted environments users can
> simply extract observed addresses from a `libp2p-identify::Event::Received { info:
> libp2p_identify::Info { observed_addr }}` and confirm them via `Swarm::add_external_address`.

Follow-up to #3954.

Pull-Request: #4052.
Uses `web-sys::WebTransport` and provides a `Transport` implementation.
@thomaseizinger
Copy link
Contributor Author

I've also extracted the send-wrapper commit into a separate PR: #4066

mergify bot pushed a commit that referenced this pull request Jun 12, 2023
Co-authored-by: Yiannis Marangos <[email protected]>

Related: #4065.

Pull-Request: #4066.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants