Skip to content

Malformed JSON error when cursor movement cancels autocomplete streaming with OpenAI provider #7282

@fsytsuta

Description

@fsytsuta

Before submitting your bug report

Relevant environment info

- OS: Windows 11
- Continue version: 1.0.24
- IDE version: VSCode 1.103.1
- Model: Qwen/Qwen3-Coder-30B-A3B-Instruct (Locally running on vllm)
- config:
  
name: Local Assistant
version: 1.0.0
schema: v1
models:
  - name: Qwen3-Coder-30B-A3B-Instruct
    provider: openai
    model: Qwen/Qwen3-Coder-30B-A3B-Instruct 
    roles:
      - autocomplete
    apiBase: http://localhost:8000/v1
    apiKey: EMPTY

Description

When using the OpenAI provider for autocomplete functionality, moving the cursor during active streaming causes incomplete JSON responses to be processed, resulting in Malformed JSON sent from server errors.

To reproduce

  1. Configure Continue extension with an OpenAI provider model (e.g., Qwen/Qwen3-Coder-30B-A3B-Instruct-FP8)
  2. Enable autocomplete functionality in VSCode
  3. Trigger code completion and move cursor while streaming is in progress
  4. Observe the following error:
Continue Autocomplete Error: Malformed JSON sent from server: {"id":"chatcmpl-...","object":"text_completion",...,"usage":{"completion_tokens":0,"prompt_token

Log output

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:autocompleteRelates to the auto complete featureide:vscodeRelates specifically to VS Code extensionkind:bugIndicates an unexpected problem or unintended behavioros:windowsHappening specifically on Windows

    Type

    No type

    Projects

    Status

    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions