-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
ClientHttp2Stream.h2StreamError from extension in code-server #6983
Comments
Is it trying to reach out to localhost or something? Some extensions do this but of course that will not work in the web, they need to use the proxy to get to the port. We should test in Codespaces though, if it is broken there then it will either be an issue with VS Code or the plugin. |
Actually it must be using the proxy, right? Otherwise the error would be "connection refused " or something. I think the package we use for proxying does not support HTTP/2. |
Here is the upstream issue: http-party/node-http-proxy#1237 Maybe there is a different package we can use 🤔 |
@code-asher Thank you for replying.
Yes. It is trying to reach out to local host. Specifically http://localhost:8877/api. I'm unfamiliar with the architecture of code-server; can you explain where a proxy gets used? I thought code-server had a server with a thin web-client. I thought the server is where the vscode extension host is running and where the RPC should be coming from. code-server is running on my laptop and so I would expect it be able to access localhost. |
Yup, code-server is mostly just a thin web client around VS Code, but it also has a simple reverse proxy. The reason being that extensions (like this) spin up their own server on some port (8877 in this case) and they need a way to access that from the local browser to the remote (where localhost will not work). The proxy is used when an extension calls So it can be that either it is trying to reach localhost:8877 from the browser and it needs to be changed to use |
Ah but yeah in your case, if it is running locally, accessing localhost will work and that means our proxy is not involved, so maybe this is some other issue entirely? It should work the same as native VS Code in that case. |
If the request runs from the browser, maybe there is some difference in the browser vs Electron with regards to http/2, so something to look into might be whether the package that is providing the http/2 connection has browser support. If the request runs from Node though, I am not sure. The only difference there from native VS Code is plain Node vs Electron but I am not sure that could be making a difference here. |
Is there an existing issue for this?
OS/Web Information
code-server --version
:4.92.2 de65bfc with Code 1.92.2
Steps to Reproduce
foyle serve
Expected
Foyle should generate a completion and insert it a cell into the notebook.
Actual
We get an error in vscode.
In the RunMe Output window we see the error
Chrome console shows the following error
I believe the error indicates there is lack of support for HTTP2 clients. It works in native vscode so I suspect the problem must be something with code-server.
Logs
No response
Screenshot/Video
No response
Does this bug reproduce in native VS Code?
No, this works as expected in native VS Code
Does this bug reproduce in GitHub Codespaces?
I did not test GitHub Codespaces
Are you accessing code-server over a secure context?
Notes
No response
The text was updated successfully, but these errors were encountered: