continuedev / continuedev/continue
VSCode plugin sends `connection: close` header which is not compliant with HTTP response streaming protocol
@sestinj is already working on this.
Since Mar 10, 2025.
- Dominant language
- TypeScript
- Stars
- 36k
- Forks
- 5.4k
- PR merge metrics
- No merged PRs in 30d
Description
Before submitting your bug report
- I believe this is a bug. I'll try to join the Continue Discord for questions
- I'm not able to find an open issue that reports the same bug
- I've seen the troubleshooting guide on the Continue Docs
Relevant environment info
- OS: Windows
- Continue version: 1.0.3
- IDE version: VSCode
- Model: Custom OpenAI-compliant server with any model
- config:
{
"models": [
{
"title": "OVMS", // custom one that follows OpenAI spec
"model": "Qwen/Qwen2.5-Coder-1.5B-Instruct",
"apiBase": "http://localhost:11338/v3",
"provider": "openai",
"apiKey": "unused"
}
],
"tabAutocompleteModel": {
"title": "OVMS", // custom one that follows OpenAI spec
"provider": "openai",
"model": "Qwen/Qwen2.5-Coder-1.5B-Instruct",
"apiBase": "http://localhost:11338/v3",
"apiKey": "unused"
},
"slashCommands": [
{
"name": "edit",
"description": "Edit selected code"
},
{
"name": "comment",
"description": "Write comments for the selected code"
},
{
"name": "share",
"description": "Export this session as markdown"
},
{
"name": "cmd",
"description": "Generate a shell command"
}
],
"customCommands": [
{
"name": "test",
"prompt": "Write a comprehensive set of unit tests for the selected code. It should setup, run tests that check for correctness including important edge cases, and teardown. Ensure that the tests are complete and sophisticated. Give the tests just as chat output, don't edit any file.",
"description": "Write unit tests for highlighted code"
}
],
"contextProviders": [
{
"name": "code",
"params": {}
},
{
"name": "docs",
"params": {}
},
{
"name": "diff",
"params": {}
},
{
"name": "open",
"params": {}
},
{
"name": "terminal",
"params": {}
},
{
"name": "problems",
"params": {}
},
{
"name": "folder",
"params": {}
},
{
"name": "codebase",
"params": {}
}
],
"embeddingsProvider": {
"provider": "free-trial"
},
"reranker": {
"name": "free-trial"
}
}
Description
Testing OpenAI compliant servers against Continue's OpenAI provider.
OpenVINO Model Server is fully compliant with OpenAI chat completions standard. However, Continue does not comply fully with OpenAI standard by specifying connection: close header in the requests.
All headers Continue sends:
Header: connection close
Header: host localhost:11338
Header: content-length 530
Header: accept application/json
Header: x-stainless-runtime node
Header: x-stainless-retry-count 0
Header: content-type application/json
Header: authorization Bearer unused
Header: user-agent OpenAI/JS 4.76.0
Header: x-stainless-arch x64
Header: x-stainless-package-version 4.76.0
Header: x-stainless-os Windows
Header: x-stainless-runtime-version v20.18.2
Header: x-stainless-lang js
Header: accept-encoding gzip,deflate
As HTTP specification states: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Connection
Connection close should be sent, when client wants the server to terminate the connection after initial processing is finished.
Keep-alive should be used for requests that require streaming responses
This causes some HTTP server implementations to shut down the streaming response generation, including OpenVINO Model Server.
Resolution: please change header connection to keep-alive
To reproduce
- Set up OpenVINO Model Server with any model
- Setup Continue to use openai provider and point to apiBase from point 1.
- Use Continue
Log output
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.