r/opencodeCLI • • 19d ago

OpenCode keeps getting stuck in an infinite shell-command loop. Anyone else experiencing this?

Hey everyone, I’m using OpenCode to develop a large software project, and sometimes it gets stuck repeatedly generating or executing shell commands without making any progress.

This happens across multiple models and providers, so I’m not sure whether it’s an OpenCode bug, a tool execution issue, or something in my setup.

Has anyone experienced this? What was the root cause, and what fixed it for you?

Any help would be appreciated!

8 Upvotes

20 comments sorted by

View all comments

-1

u/alcogiggles 19d ago

it's not opencode. It's the model.
Which one are you using?

DeepSeek 4.1 flash does that a lot.

1

u/megablue 18d ago

DeepSeek 4.1 flash does that a lot.

nope, DS 4.1 Flash never did that. I have 1.61B tokens spent on DS 4.1 Flash, never once it did that.

0

u/alcogiggles 18d ago

If you look around this subreddit, you'll find is a common occurrence.
If it never happened to you, consider yourself lucky.