Scoop-fixes-opencode-windows-x64-garbled-output-issue-but-cause-unknown #7410

Closed
opened 2026-02-16 18:07:05 -05:00 by yindo · 3 comments
Owner

Originally created by @mizaibear on GitHub (Jan 24, 2026).

Originally assigned to: @rekram1-node on GitHub.

Question

System Environment

  • Windows 10 x64_22h2

Initial Problem Discovery

Direct Download from GitHub Release

https://github.com/anomalyco/opencode/releases/download/v1.1.34/opencode-windows-x64.zip

Image

Extracted to Installation Directory and Added to env.PATH

Example: "D:\SoftwareWorkspace\opencode_x64\opencode.exe"

Launched via opencode Command in Windows Terminal or by Double-clicking opencode.exe

Result: After launch, all input becomes uncontrolled and displays garbled text. Even mouse movements generate massive amounts of garbled output, making normal usage impossible.

Image

Installing opencode-windows-x64 via Scoop Resolves This Issue

scoop install opencode

After installation via Scoop, the application works correctly.

Image

Strange Phenomena Discovered While Investigating Why Scoop Fixes the Problem

According to Scoop's Bucket Metadata, It Uses the Same Download Link

// ~\scoop\buckets\main\bucket\opencode.json
{
    "version": "1.1.34",
    "description": "The open source AI coding agent.",
    "homepage": "https://opencode.ai/",
    "license": "MIT",
    "architecture": {
        "64bit": {
            "url": "https://github.com/anomalyco/opencode/releases/download/v1.1.34/opencode-windows-x64.zip",
            "hash": "2ecf5682187714057cd51c178ae29687672a2bd753a919d3d1d49591d23a1fec"
        }
    },
    "bin": "opencode.exe",
    "checkver": {
        "github": "https://github.com/anomalyco/opencode"
    },
    "autoupdate": {
        "architecture": {
            "64bit": {
                "url": "https://github.com/anomalyco/opencode/releases/download/v$version/opencode-windows-x64.zip"
            }
        }
    }
}

So Why Does Scoop Installation Work While Browser Download + Extract Fails?

I located the Scoop-installed program path:

# scoop shims link
~\scoop\shims\opencode.exe
# link to real exe file
~\scoop\apps\opencode\1.1.34\opencode.exe

Test 1: Copy Scoop-Installed Program and Run Outside

When copied to the same location (e.g., C: drive root) and executed directly, the garbled output bug reappears.

cp "~\scoop\apps\opencode\1.1.34\opencode.exe" "C:\opencode.exe"
# execute outside of scoop
. "C:\opencode.exe"
Image

Test 2: Copy Originally Broken File to Scoop Directory

When I copy the original problematic file into any location within the Scoop directory, the problem disappears and no garbled output occurs.
BugFixed Only When ExeFile in Scoop Folder to Run:I wonder How?
Conclusion: This is not a file difference issue.

The Core Question: What Exactly Does Scoop Do?

Why does simply copying the file into the Scoop directory fix the problem?

I tested scoop shim add with the external exe file, but the garbled output issue persists. So it's not the shim mechanism—there must be something about copying the file into the Scoop directory that triggers the fix.

I want to understand what processing Scoop does during installation that resolves this wrapper issue.

Originally created by @mizaibear on GitHub (Jan 24, 2026). Originally assigned to: @rekram1-node on GitHub. ### Question ## System Environment - Windows 10 x64_22h2 ## Initial Problem Discovery ### Direct Download from GitHub Release https://github.com/anomalyco/opencode/releases/download/v1.1.34/opencode-windows-x64.zip <img width="1439" height="906" alt="Image" src="https://github.com/user-attachments/assets/20ed1129-25b5-44d1-8074-c7b67375a91f" /> ### Extracted to Installation Directory and Added to env.PATH Example: `"D:\SoftwareWorkspace\opencode_x64\opencode.exe"` ### Launched via `opencode` Command in Windows Terminal or by Double-clicking opencode.exe **Result**: After launch, all input becomes uncontrolled and displays garbled text. Even mouse movements generate massive amounts of garbled output, making normal usage impossible. <img width="1565" height="1030" alt="Image" src="https://github.com/user-attachments/assets/0e3dda22-ef27-4a2e-bc3a-923583189bae" /> ## Installing opencode-windows-x64 via Scoop Resolves This Issue ``` scoop install opencode ``` After installation via Scoop, the application works correctly. <img width="1972" height="1076" alt="Image" src="https://github.com/user-attachments/assets/ef9bd568-642c-4d09-aa3a-1ed562dbd192" /> ## Strange Phenomena Discovered While Investigating Why Scoop Fixes the Problem ### According to Scoop's Bucket Metadata, It Uses the Same Download Link ```json // ~\scoop\buckets\main\bucket\opencode.json { "version": "1.1.34", "description": "The open source AI coding agent.", "homepage": "https://opencode.ai/", "license": "MIT", "architecture": { "64bit": { "url": "https://github.com/anomalyco/opencode/releases/download/v1.1.34/opencode-windows-x64.zip", "hash": "2ecf5682187714057cd51c178ae29687672a2bd753a919d3d1d49591d23a1fec" } }, "bin": "opencode.exe", "checkver": { "github": "https://github.com/anomalyco/opencode" }, "autoupdate": { "architecture": { "64bit": { "url": "https://github.com/anomalyco/opencode/releases/download/v$version/opencode-windows-x64.zip" } } } } ``` ### So Why Does Scoop Installation Work While Browser Download + Extract Fails? I located the Scoop-installed program path: ``` # scoop shims link ~\scoop\shims\opencode.exe # link to real exe file ~\scoop\apps\opencode\1.1.34\opencode.exe ``` #### Test 1: Copy Scoop-Installed Program and Run Outside When copied to the same location (e.g., C: drive root) and executed directly, the garbled output bug reappears. ```powershell cp "~\scoop\apps\opencode\1.1.34\opencode.exe" "C:\opencode.exe" # execute outside of scoop . "C:\opencode.exe" ``` <img width="1134" height="1082" alt="Image" src="https://github.com/user-attachments/assets/54c2e930-e19c-4825-8ff7-c0b6da070961" /> #### Test 2: Copy Originally Broken File to Scoop Directory When I copy the original problematic file into **any location** within the Scoop directory, the problem disappears and no garbled output occurs. **BugFixed Only When ExeFile in Scoop Folder to Run**:I wonder How? **Conclusion**: This is not a file difference issue. ### The Core Question: What Exactly Does Scoop Do? Why does simply copying the file into the Scoop directory fix the problem? I tested `scoop shim add` with the external exe file, but the garbled output issue persists. So it's not the shim mechanism—there must be something about copying the file into the Scoop directory that triggers the fix. **I want to understand what processing Scoop does during installation that resolves this wrapper issue.**
yindo added the windowsopentui labels 2026-02-16 18:07:05 -05:00
yindo closed this issue 2026-02-16 18:07:05 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Jan 24, 2026):

This issue might be a duplicate of existing issues. Please check:

  • #9814: Garbled characters appear after launching the program on Windows system
  • #8908: Mouse wheel triggering abnormal ASCII codes after exiting (Scoop installation also resolves this)
  • #9338: TUI rendering with random characters like â and € on Windows 11
  • #9183: Ctrl+C causes serialization issues in CLI TUI version
  • #8715: Opencode Windows Character Spamming

Feel free to ignore if none of these address your specific case.

@github-actions[bot] commented on GitHub (Jan 24, 2026): This issue might be a duplicate of existing issues. Please check: - #9814: Garbled characters appear after launching the program on Windows system - #8908: Mouse wheel triggering abnormal ASCII codes after exiting (Scoop installation also resolves this) - #9338: TUI rendering with random characters like â and € on Windows 11 - #9183: Ctrl+C causes serialization issues in CLI TUI version - #8715: Opencode Windows Character Spamming Feel free to ignore if none of these address your specific case.
Author
Owner

@DoiiarX commented on GitHub (Jan 27, 2026):

Image我无论如何都是可以的。我手动复制过去的

@DoiiarX commented on GitHub (Jan 27, 2026): <img width="2282" height="1390" alt="Image" src="https://github.com/user-attachments/assets/ce630a90-6996-4d07-b06a-9680df3c2974" />我无论如何都是可以的。我手动复制过去的
Author
Owner

@mizaibear commented on GitHub (Jan 27, 2026):

@DoiiarX ,
感谢回复!

UPDATE:我赶紧去试了一下,发现原本会花屏的那个情况确实消失了。我记起来这几天改过了Powershell的UTF-8编码,也就是说之前花屏是Windows默认编码造成的,改成UTF-8就没事了。

@mizaibear commented on GitHub (Jan 27, 2026): @DoiiarX , 感谢回复! ---- UPDATE:我赶紧去试了一下,发现原本会花屏的那个情况确实消失了。我记起来这几天改过了Powershell的UTF-8编码,也就是说之前花屏是Windows默认编码造成的,改成UTF-8就没事了。
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#7410