When model uses edit tool it returns status 126 #776

Closed
opened 2026-02-16 17:28:14 -05:00 by yindo · 15 comments
Owner

Originally created by @DiedeClaessens on GitHub (Jul 17, 2025).

Originally assigned to: @rekram1-node on GitHub.

When the model wants to edit my files it returns status 136. But the actual file is edited.

Image

Originally created by @DiedeClaessens on GitHub (Jul 17, 2025). Originally assigned to: @rekram1-node on GitHub. When the model wants to edit my files it returns status 136. But the actual file is edited.  <img width="564" height="86" alt="Image" src="https://github.com/user-attachments/assets/5821920f-21ce-44df-a89a-4cb6aa2df3cb" />
yindo closed this issue 2026-02-16 17:28:14 -05:00
Author
Owner

@thdxr commented on GitHub (Jul 17, 2025):

what model is this?

@thdxr commented on GitHub (Jul 17, 2025): what model is this?
Author
Owner

@thdxr commented on GitHub (Jul 17, 2025):

oh this maybe is related to a formatter? what kind of file is this

@thdxr commented on GitHub (Jul 17, 2025): oh this maybe is related to a formatter? what kind of file is this
Author
Owner

@DiedeClaessens commented on GitHub (Jul 18, 2025):

Elixir and does not matter what model I use, they all have it

@DiedeClaessens commented on GitHub (Jul 18, 2025): Elixir and does not matter what model I use, they all have it
Author
Owner

@DiedeClaessens commented on GitHub (Jul 24, 2025):

@thdxr sorry to bother you again but could you maybe give me some guidance how to fix. Could not find it in the docs?

@DiedeClaessens commented on GitHub (Jul 24, 2025): @thdxr sorry to bother you again but could you maybe give me some guidance how to fix. Could not find it in the docs?
Author
Owner

@objectuser commented on GitHub (Aug 20, 2025):

I'm having this same issue.

@objectuser commented on GitHub (Aug 20, 2025): I'm having this same issue.
Author
Owner

@rekram1-node commented on GitHub (Aug 20, 2025):

@objectuser are you only having it w/ elixir?

@rekram1-node commented on GitHub (Aug 20, 2025): @objectuser are you only having it w/ elixir?
Author
Owner

@objectuser commented on GitHub (Aug 20, 2025):

@objectuser are you only having it w/ elixir?

It is with Elixir and yes only with Elixir but that's also only how I'm using it.

I'm suspicious that it's asdf.

Really new to opencode but found:

ERROR 2025-08-20T13:41:37 +324ms service=default e=Failed with exit code 126 rejection

But also:

INFO 2025-08-20T13:56:06 +0ms service=format command=["mix","format","$FILE"] running

No errors around ☝️ . 🤔

@objectuser commented on GitHub (Aug 20, 2025): > [@objectuser](https://github.com/objectuser) are you only having it w/ elixir? It is with Elixir and yes only with Elixir but that's also only how I'm using it. I'm suspicious that it's `asdf`. Really new to opencode but found: > ERROR 2025-08-20T13:41:37 +324ms service=default e=Failed with exit code 126 rejection But also: > INFO 2025-08-20T13:56:06 +0ms service=format command=["mix","format","$FILE"] running No errors around ☝️ . 🤔
Author
Owner

@rekram1-node commented on GitHub (Aug 20, 2025):

sweet, I will try to fix this for ya when I get a second later tonight

@rekram1-node commented on GitHub (Aug 20, 2025): sweet, I will try to fix this for ya when I get a second later tonight
Author
Owner

@objectuser commented on GitHub (Aug 20, 2025):

🍻

@objectuser commented on GitHub (Aug 20, 2025): 🍻
Author
Owner

@rekram1-node commented on GitHub (Aug 22, 2025):

@objectuser looking into this more I think it is probably something specific to you? not sure if there is anything for us to do on our end maybe formatters shouldn't send errors to context but idk what else?

@rekram1-node commented on GitHub (Aug 22, 2025): @objectuser looking into this more I think it is probably something specific to you? not sure if there is anything for us to do on our end maybe formatters shouldn't send errors to context but idk what else?
Author
Owner

@objectuser commented on GitHub (Aug 22, 2025):

OK thanks, @rekram1-node. I wonder if everyone using Elixir is getting the same error. opencode is completing Elixir tasks (code modifications, etc.) successfully.

I'll continue to look around, maybe ask in some Elixir venues.

@objectuser commented on GitHub (Aug 22, 2025): OK thanks, @rekram1-node. I wonder if everyone using Elixir is getting the same error. opencode is completing Elixir tasks (code modifications, etc.) successfully. I'll continue to look around, maybe ask in some Elixir venues.
Author
Owner

@rekram1-node commented on GitHub (Aug 23, 2025):

i could be mistaken here btw, just out of curiosity what is your mix path? like where is it located, does it require something custom from your .zshrc or something to get loaded properly?

we are running the mix … command but we arent sourcing your zshrc etc, but if mix is resolved through PATH properly it shouldnt be an issue

@rekram1-node commented on GitHub (Aug 23, 2025): i could be mistaken here btw, just out of curiosity what is your mix path? like where is it located, does it require something custom from your .zshrc or something to get loaded properly? we are running the mix … command but we arent sourcing your zshrc etc, but if mix is resolved through PATH properly it shouldnt be an issue
Author
Owner

@objectuser commented on GitHub (Aug 23, 2025):

I'm using mix through asdf which is in my path.

I just found out I get improved results when I disable elixir-ls.

  "lsp": {
    "elixir-ls": {
      "disabled": true
    }
  },

No error is generated and for the first time I see a diff of the edits.

@objectuser commented on GitHub (Aug 23, 2025): I'm using mix through asdf which is in my path. I just found out I get improved results when I disable `elixir-ls`. ``` "lsp": { "elixir-ls": { "disabled": true } }, ``` No error is generated and for the first time I see a diff of the edits.
Author
Owner

@rekram1-node commented on GitHub (Aug 25, 2025):

ahh elixir lsp separate issue that makes more sense, for some reason I was thinking formatter

@rekram1-node commented on GitHub (Aug 25, 2025): ahh elixir lsp separate issue that makes more sense, for some reason I was thinking formatter
Author
Owner

@rekram1-node commented on GitHub (Sep 22, 2025):

haven't seen activity on this one in a while closing unless more people have this issue

@rekram1-node commented on GitHub (Sep 22, 2025): haven't seen activity on this one in a while closing unless more people have this issue
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#776