always stuck at “Preparing write...” #7926

Open
opened 2026-02-16 18:08:41 -05:00 by yindo · 20 comments
Owner

Originally created by @yinzhou-jc on GitHub (Jan 29, 2026).

Originally assigned to: @rekram1-node on GitHub.

Description

My Prometheus always stuck at “Preparing write...”。

I am using the latest oh-my-opencode and opencode.

Thinking: 让我重新尝试写入工作计划文件。
~ Preparing write...
Tool execution aborted
Thinking: 好的,让我重新尝试写入工作计划文件。
~ Preparing write...
Tool execution aborted
Thinking: 用户让我重试写入工作计划。让我重新写入计划文件。
好的,让我重新生成工作计划:
~ Preparing write...
Tool execution aborted

Plugins

No response

OpenCode version

No response

Steps to reproduce

No response

Screenshot and/or share link

No response

Operating System

No response

Terminal

No response

Originally created by @yinzhou-jc on GitHub (Jan 29, 2026). Originally assigned to: @rekram1-node on GitHub. ### Description My Prometheus always stuck at “Preparing write...”。 I am using the latest oh-my-opencode and opencode. ``` Thinking: 让我重新尝试写入工作计划文件。 ~ Preparing write... Tool execution aborted Thinking: 好的,让我重新尝试写入工作计划文件。 ~ Preparing write... Tool execution aborted Thinking: 用户让我重试写入工作计划。让我重新写入计划文件。 好的,让我重新生成工作计划: ~ Preparing write... Tool execution aborted ``` ### Plugins _No response_ ### OpenCode version _No response_ ### Steps to reproduce _No response_ ### Screenshot and/or share link _No response_ ### Operating System _No response_ ### Terminal _No response_
yindo added the bug label 2026-02-16 18:08:41 -05:00
Author
Owner

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

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

  • #2144: opencode stucks while trying to write a file
  • #1100: Tool execution aborted
  • #268: write tool sometimes has a "request was aborted" result

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

@github-actions[bot] commented on GitHub (Jan 29, 2026): This issue might be a duplicate of existing issues. Please check: - #2144: opencode stucks while trying to write a file - #1100: Tool execution aborted - #268: write tool sometimes has a "request was aborted" result Feel free to ignore if none of these address your specific case.
Author
Owner

@marcinpz commented on GitHub (Jan 29, 2026):

Same here:

Image
@marcinpz commented on GitHub (Jan 29, 2026): Same here: <img width="365" height="88" alt="Image" src="https://github.com/user-attachments/assets/41b3e859-16bf-4e85-970e-3404f0f6f3f4" />
Author
Owner

@vidyanand commented on GitHub (Jan 29, 2026):

I am facing the same issues as well. I am using 1.1.40 version and am using claude-sonner through github copilot.

Image
@vidyanand commented on GitHub (Jan 29, 2026): I am facing the same issues as well. I am using 1.1.40 version and am using claude-sonner through github copilot. <img width="474" height="237" alt="Image" src="https://github.com/user-attachments/assets/81dbb248-b148-4181-a103-8403737491a4" />
Author
Owner

@andriy-ah commented on GitHub (Jan 29, 2026):

Same issue with GH Copilot and Sonnet 4.5, Haiku 4.5.
Switched to Gemini and it worked.

@andriy-ah commented on GitHub (Jan 29, 2026): Same issue with GH Copilot and Sonnet 4.5, Haiku 4.5. Switched to Gemini and it worked.
Author
Owner

@Ylandolsi commented on GitHub (Jan 29, 2026):

Same issue with GH Copilot and Sonnet 4.5, Haiku 4.5. Switched to Gemini and it worked.

Image Image

same thing here

@Ylandolsi commented on GitHub (Jan 29, 2026): > Same issue with GH Copilot and Sonnet 4.5, Haiku 4.5. Switched to Gemini and it worked. <img width="600" height="157" alt="Image" src="https://github.com/user-attachments/assets/6f54df4e-5d8a-4a18-b495-82a6949aacf6" /> <img width="837" height="233" alt="Image" src="https://github.com/user-attachments/assets/9192e60f-6beb-4ee3-92ce-81e2935fe5bc" /> same thing here
Author
Owner

@vaguilarrebolledo commented on GitHub (Jan 29, 2026):

same issue with claude-opus-4.5

Image
@vaguilarrebolledo commented on GitHub (Jan 29, 2026): same issue with claude-opus-4.5 <img width="1046" height="324" alt="Image" src="https://github.com/user-attachments/assets/df006b0b-fd61-4bfb-b3c7-f6450e23d143" />
Author
Owner

@rekram1-node commented on GitHub (Jan 29, 2026):

Going to investigate

@rekram1-node commented on GitHub (Jan 29, 2026): Going to investigate
Author
Owner

@allen-n commented on GitHub (Jan 29, 2026):

Seeing this as well, some debug info:

opencode --version
1.1.42

model provider: github copilot, opus 4.5

@allen-n commented on GitHub (Jan 29, 2026): Seeing this as well, some debug info: ```sh opencode --version 1.1.42 ``` model provider: github copilot, opus 4.5
Author
Owner

@vaguilarrebolledo commented on GitHub (Jan 29, 2026):

i connected with github copilot provider

@vaguilarrebolledo commented on GitHub (Jan 29, 2026): i connected with github copilot provider
Author
Owner

@spoons-and-mirrors commented on GitHub (Jan 29, 2026):

are you guys using any plugin ?

@spoons-and-mirrors commented on GitHub (Jan 29, 2026): are you guys using any plugin ?
Author
Owner

@allen-n commented on GitHub (Jan 29, 2026):

@spoons-and-mirrors No, but it does seem like we are all using copilot

@allen-n commented on GitHub (Jan 29, 2026): @spoons-and-mirrors No, but it does seem like we are all using copilot
Author
Owner

@allen-n commented on GitHub (Jan 29, 2026):

Seeing the issue with Codex 5.2 with OpenAI as the provider as well - it seems like the foreground agent is unable to write files, but delegated sub-agents don't seem to have the issue for me.

@allen-n commented on GitHub (Jan 29, 2026): Seeing the issue with Codex 5.2 with OpenAI as the provider as well - it seems like the foreground agent is unable to write files, but delegated sub-agents don't seem to have the issue for me.
Author
Owner

@rekram1-node commented on GitHub (Jan 29, 2026):

Can anyone export a session to me? Or steps to replicate?

opencode export > session.json

^^ run this command in ur terminal and then send file

@rekram1-node commented on GitHub (Jan 29, 2026): Can anyone export a session to me? Or steps to replicate? `opencode export > session.json` ^^ run this command in ur terminal and then send file
Author
Owner

@andriy-ah commented on GitHub (Jan 30, 2026):

@rekram1-node seems like it is working now, but here is the part where tool call failed from yesterday's session:

[
  // ...
  {
    "info": {
      "id": "msg_c09a76e9e001xyz38GiAvOAFRw",
      "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb",
      "role": "user",
      "time": {
        "created": 1769688493729
      },
      "summary": {
        "diffs": []
      },
      "agent": "build",
      "model": {
        "providerID": "github-copilot",
        "modelID": "claude-haiku-4.5"
      }
    },
    "parts": [
      {
        "id": "prt_c09a76e9e002wbA83qUCShrBJr",
        "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb",
        "messageID": "msg_c09a76e9e001xyz38GiAvOAFRw",
        "type": "text",
        "text": "save all the results to the file, why can't you do that?"
      }
    ]
  },
  {
    "info": {
      "id": "msg_c09a76ea8002fYoppehA3Eijdk",
      "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb",
      "role": "assistant",
      "time": {
        "created": 1769688493736,
        "completed": 1769688534265
      },
      "parentID": "msg_c09a76e9e001xyz38GiAvOAFRw",
      "modelID": "claude-haiku-4.5",
      "providerID": "github-copilot",
      "mode": "build",
      "agent": "build",
      "path": {
        "cwd": "/Users/someuser/someproject",
        "root": "/"
      },
      "cost": 0,
      "tokens": {
        "input": 2,
        "output": 4096,
        "reasoning": 0,
        "cache": {
          "read": 0,
          "write": 34431
        }
      },
      "finish": "length"
    },
    "parts": [
      {
        "id": "prt_c09a80cf3001GD9qhzGc63wo30",
        "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb",
        "messageID": "msg_c09a76ea8002fYoppehA3Eijdk",
        "type": "step-start"
      },
      {
        "id": "prt_c09a80cf5001RDhPazQM3JRIfw",
        "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb",
        "messageID": "msg_c09a76ea8002fYoppehA3Eijdk",
        "type": "text",
        "text": "You're right, let me save all the results to research.md now:",
        "time": {
          "start": 1769688534262,
          "end": 1769688534262
        }
      },
      {
        "id": "prt_c09a80cf70014f1VT4ZXaBoS8s",
        "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb",
        "messageID": "msg_c09a76ea8002fYoppehA3Eijdk",
        "type": "tool",
        "callID": "toolu_01YRJiwC85eTMoVpUhVZ2qi8",
        "tool": "write",
        "state": {
          "status": "error",
          "input": {},
          "error": "Tool execution aborted",
          "time": {
            "start": 1769688534265,
            "end": 1769688534265
          }
        }
      },
      {
        "id": "prt_c09a80cf7002NIdqXVSWvEP4bd",
        "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb",
        "messageID": "msg_c09a76ea8002fYoppehA3Eijdk",
        "type": "step-finish",
        "reason": "length",
        "cost": 0,
        "tokens": {
          "input": 2,
          "output": 4096,
          "reasoning": 0,
          "cache": {
            "read": 0,
            "write": 34431
          }
        }
      }
    ]
  }
  // ...
]

@andriy-ah commented on GitHub (Jan 30, 2026): @rekram1-node seems like it is working now, but here is the part where tool call failed from yesterday's session: ```jsonc [ // ... { "info": { "id": "msg_c09a76e9e001xyz38GiAvOAFRw", "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb", "role": "user", "time": { "created": 1769688493729 }, "summary": { "diffs": [] }, "agent": "build", "model": { "providerID": "github-copilot", "modelID": "claude-haiku-4.5" } }, "parts": [ { "id": "prt_c09a76e9e002wbA83qUCShrBJr", "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb", "messageID": "msg_c09a76e9e001xyz38GiAvOAFRw", "type": "text", "text": "save all the results to the file, why can't you do that?" } ] }, { "info": { "id": "msg_c09a76ea8002fYoppehA3Eijdk", "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb", "role": "assistant", "time": { "created": 1769688493736, "completed": 1769688534265 }, "parentID": "msg_c09a76e9e001xyz38GiAvOAFRw", "modelID": "claude-haiku-4.5", "providerID": "github-copilot", "mode": "build", "agent": "build", "path": { "cwd": "/Users/someuser/someproject", "root": "/" }, "cost": 0, "tokens": { "input": 2, "output": 4096, "reasoning": 0, "cache": { "read": 0, "write": 34431 } }, "finish": "length" }, "parts": [ { "id": "prt_c09a80cf3001GD9qhzGc63wo30", "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb", "messageID": "msg_c09a76ea8002fYoppehA3Eijdk", "type": "step-start" }, { "id": "prt_c09a80cf5001RDhPazQM3JRIfw", "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb", "messageID": "msg_c09a76ea8002fYoppehA3Eijdk", "type": "text", "text": "You're right, let me save all the results to research.md now:", "time": { "start": 1769688534262, "end": 1769688534262 } }, { "id": "prt_c09a80cf70014f1VT4ZXaBoS8s", "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb", "messageID": "msg_c09a76ea8002fYoppehA3Eijdk", "type": "tool", "callID": "toolu_01YRJiwC85eTMoVpUhVZ2qi8", "tool": "write", "state": { "status": "error", "input": {}, "error": "Tool execution aborted", "time": { "start": 1769688534265, "end": 1769688534265 } } }, { "id": "prt_c09a80cf7002NIdqXVSWvEP4bd", "sessionID": "ses_3f6615053ffeU9Kp5weksjY9xb", "messageID": "msg_c09a76ea8002fYoppehA3Eijdk", "type": "step-finish", "reason": "length", "cost": 0, "tokens": { "input": 2, "output": 4096, "reasoning": 0, "cache": { "read": 0, "write": 34431 } } } ] } // ... ] ```
Author
Owner

@shiw-yang commented on GitHub (Feb 9, 2026):

I also encountered a similar issue while using GitHub Copilot subscription. It often happens when writing slightly larger files, which wasted a lot of my tokens

@shiw-yang commented on GitHub (Feb 9, 2026): I also encountered a similar issue while using GitHub Copilot subscription. It often happens when writing slightly larger files, which wasted a lot of my tokens
Author
Owner

@Quadrapole commented on GitHub (Feb 13, 2026):

I'm getting:

~ Preparing write...
Tool execution aborted
"Invalid diff: now finding less tool calls!"

as well.

On opencode with oh-my-code running locally with qwen3 80b next q4k_m.

pls help :(

@Quadrapole commented on GitHub (Feb 13, 2026): I'm getting: ~ Preparing write... Tool execution aborted "Invalid diff: now finding less tool calls!" as well. On opencode with oh-my-code running locally with qwen3 80b next q4k_m. pls help :(
Author
Owner

@yu-zou commented on GitHub (Feb 15, 2026):

Same issue when writing large contents into a file. I'm using Github Copilot Claude Opus 4.5.

@yu-zou commented on GitHub (Feb 15, 2026): Same issue when writing large contents into a file. I'm using Github Copilot Claude Opus 4.5.
Author
Owner

@FN-FAL113 commented on GitHub (Feb 16, 2026):

Having same issue but running with local model through LM Studio using glm-4.7-flash. It generated more than 4k tokens in LM studio but still haven't made any changes to the concerning code file

Image
@FN-FAL113 commented on GitHub (Feb 16, 2026): Having same issue but running with local model through LM Studio using glm-4.7-flash. It generated more than 4k tokens in LM studio but still haven't made any changes to the concerning code file <img width="550" height="328" alt="Image" src="https://github.com/user-attachments/assets/6d652dde-eb56-4ebd-9026-954ffb688e4c" />
Author
Owner

@netandreus commented on GitHub (Feb 16, 2026):

Same for me guys :(

Image
(base) andrey@m2 ~ % opencode -v
1.1.51
@netandreus commented on GitHub (Feb 16, 2026): Same for me guys :( <img width="866" height="184" alt="Image" src="https://github.com/user-attachments/assets/d352247c-d30c-4719-990c-d0aabb4c0832" /> ```bash (base) andrey@m2 ~ % opencode -v 1.1.51 ```
Author
Owner

@FN-FAL113 commented on GitHub (Feb 16, 2026):

Might be hallucinations, I aborted mine and it spit out garbled tokens and non-english tokens.

@FN-FAL113 commented on GitHub (Feb 16, 2026): Might be hallucinations, I aborted mine and it spit out garbled tokens and non-english tokens.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#7926