Apply incorrectly clears the entire file content and ends with "Unknown error"

Issue Description

Apply incorrectly clears the entire file content and ends with “Unknown error”.

The issue started recently. Previously, the Apply feature worked correctly and only modified the affected code fragments.

Now, when I click Apply, Qoder generates a diff where the entire content of the target file is marked for removal instead of showing only the intended changes. After clicking Apply, a popup appears with the message “Unknown error”, and no changes are applied.

The issue is reproducible with different programming languages (C#, SCSS, etc.) and with different models.

Steps to Reproduce

  1. Open any project in Rider.
  2. Ask Qoder to modify an existing file.
  3. Wait until Qoder generates a code block with the suggested changes.
  4. Click the Apply button.
  5. Review the generated diff.

Expected Behavior

  • Qoder should generate a diff containing only the modified code fragments.
  • Clicking Apply should update only those fragments.
  • The operation should complete successfully without any errors.

Actual Behavior

The generated diff marks the entire content of the file for removal instead of only the modified fragments.
Clicking Apply displays a popup with the message “Unknown error”.
No changes are applied.

The only related log entry is:

INFO - #com.alibabacloud.intellij.qoder.ui.search.component.markdown.CodeMarkdownHighlightComponent Apply start, applyId=..., targetFile=..., requestId=..., sessionId=...

Screenshots / Screen Recordings

image

Operating System

Windows 11 x64

Current Qoder Version (Menu → About Qoder → Copy)

Qoder Plugin: 0.19.2

IDE: JetBrains Rider 2026.1.3