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

ERR_METHOD_NOT_SUPPORTED, Opening handshake failed. #237

Closed
guest271314 opened this issue Nov 13, 2021 · 14 comments
Closed

ERR_METHOD_NOT_SUPPORTED, Opening handshake failed. #237

guest271314 opened this issue Nov 13, 2021 · 14 comments

Comments

@guest271314
Copy link
Contributor

At terminal

2021-11-13 11:39:45,945 INFO quic [4654232e7292bb80] ALPN negotiated protocol h3
2021-11-13 11:39:45,947 INFO quic [4654232e7292bb80] Connection close sent (code 0x109, reason ENABLE_WEBTRANSPORT requires H3_DATAGRAM)

At browser

Failed to establish a connection to https://quic.aiortc.org/wt: net::ERR_METHOD_NOT_SUPPORTED.
VM23:11 Opening handshake failed.
(anonymous) @ VM23:11
Promise.catch (async)
(anonymous) @ VM23:10
quic.aiortc.org/:1 Uncaught (in promise) WebTransportError: Opening handshake failed.

Steps to reeproduce:

Follow instructions at examples/README for Chromium.

Potentially related GoogleChrome/samples#749 (comment), GoogleChrome/samples@b83dc66.

@jlaine
Copy link
Contributor

jlaine commented Dec 30, 2021

Not enough information about what you are doing here. What's your server, what's your client?

@jlaine jlaine closed this as completed Dec 30, 2021
@guest271314
Copy link
Contributor Author

Running the examples in this repository on Chromium.

@jlaine
Copy link
Contributor

jlaine commented Dec 31, 2021

I'm not a Chromium maintainer. Either you help me pinpoint a problem specifically in the code I wrote or I suggest you look elsewhere for help.

@guest271314
Copy link
Contributor Author

What happens when you run the WebTransport example code of Chronmium/Chrome? Do you get a handshake error?

@guest271314
Copy link
Contributor Author

Not enough information about what you are doing here. What's your server, what's your client?

Following instructions at https://github.com/aiortc/aioquic/tree/main/examples on Chromium 99.0.4802.0 (Developer Build) (64-bit)

$ python3 examples/http3_server.py --certificate tests/ssl_cert.pem --private-key tests/ssl_key.pem
2022-01-02 04:44:28,758 INFO quic [c9e1a9847a619c4e] ALPN negotiated protocol h3
2022-01-02 04:44:28,761 INFO quic [c9e1a9847a619c4e] HTTP request CONNECT /wt
2022-01-02 04:44:28,764 INFO quic [c9e1a9847a619c4e] Stream 0 reset by peer (error code 268, final size 127)
let transport = new WebTransport('https://localhost:4433/wt');
await transport.ready;

let stream = await transport.createBidirectionalStream();
let reader = stream.readable.getReader();
let writer = stream.writable.getWriter()

await writer.write(new Uint8Array([65, 66, 67]));
let received = await reader.read();
await transport.close();

console.log('received', received);
Failed to establish a connection to https://localhost:4433/wt: net::ERR_METHOD_NOT_SUPPORTED.
Uncaught WebTransportError: Opening handshake failed.
tab.html:1 Uncaught (in promise) WebTransportError: Opening handshake failed.

@BruceChai-SM
Copy link

@guest271314 Have you got the way to fix this error? I am currently having this same problem. Thanks!

@guest271314
Copy link
Contributor Author

@BruceChai-SM I have not found a fix.

@Niek
Copy link

Niek commented Jan 12, 2022

Same issue here, related comment I saw in the Chromium bug: https://bugs.chromium.org/p/chromium/issues/detail?id=1011392#c107

@guest271314
Copy link
Contributor Author

@Niek The relevant parties do not appear to be interested in fixing the issue. My goal experimenting with WebTransport was for live-streaming media #242. That does not appear to be possible using either GoogleChrome/samples code or aioquic.

@Niek
Copy link

Niek commented Jan 13, 2022

@guest271314 I found a working code sample here:
https://github.com/GoogleChrome/samples/blob/gh-pages/webtransport/webtransport_server.py

It's strange that WebTransport requires such a specific HTTP/3 server setup.

@guest271314
Copy link
Contributor Author

@Niek Yes, that code runs, though does not support live-streaming. I also do not gather why Chromium authors who updated WebTransport in GoogleChrome/samples did not update code in the main dependency. I mentioned this handshake error in a PR there.

@BruceChai-SM
Copy link

@guest271314 I found a working code sample here:

https://github.com/GoogleChrome/samples/blob/gh-pages/webtransport/webtransport_server.py

It's strange that WebTransport requires such a specific HTTP/3 server setup.

👍Yeah, I also found this example works today.

@BruceChai-SM
Copy link

@Niek Yes, that code runs, though does not support live-streaming. I also do not gather why Chromium authors who updated WebTransport in GoogleChrome/samples did not update code in the main dependency. I mentioned this handshake error in a PR there.

Thanks, @guest271314 Can you share the link to the PR please?

@guest271314
Copy link
Contributor Author

@BruceChai-SM Works in general, yes, using the code published, except for the unmerged PR that fixes reading bidirectional stream GoogleChrome/samples#752. I have not achieved the requirement of live-streaming media GoogleChrome/samples#756. The stream and datagram eventual grow in internal buffer size (should not be buffered at all), and stops streaming.

Can you share the link to the PR please?

GoogleChrome/samples#749

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

No branches or pull requests

4 participants