[Bug]: OpenDevin freezes when an interactive CLI program is called
Is there an existing issue for the same bug?
- [X] I have checked the troubleshooting document at https://github.com/OpenDevin/OpenDevin/blob/main/docs/guides/Troubleshooting.md
- [X] I have checked the existing issues.
Describe the bug
When OpenDevin executes a command that is interactive (requiring user input) it freezes and spins with high CPU usage.
For instance, some examples are nano and git push.
There are a few solutions:
- Throw an error when an interactive program is run
- Allow OpenDevin to interact with interactive programs
Current Version
commit 454e9613b0b4c7a9dbb2b8273aff0b36c4d8a2bb (HEAD -> main, origin/main, origin/HEAD)
Author: yaroslavMain <[email protected]>
Date: Sun Apr 21 22:41:04 2024 +0300
Installation and Configuration
N/A
Model and Agent
No response
Reproduction Steps
- Get the agent to run an interactive command, such as saying "modify README.md with nano"
Logs, Errors, Screenshots, and Additional Context
No response
I wonder if PR https://github.com/OpenDevin/OpenDevin/pull/1347 may improve the experience with this a little bit? Probably not a solution, but it tries adding to the prompt a specific prohibition to use some interactive programs:
* don't run interactive text editors (e.g. 'nano' or 'vim'), instead use the 'write' or 'read' action.
I'm curious to see the effect since I run GPT-3.5 quite a lot and it keeps doing this.
Certainly looks like it will make it better, although maybe not fix the problem
I believe we have a timeout set, but it's something like 2m (to make sure there's enough time for sth like an npm install)
Not sure what a good solution would be here...
An auxiliary problem (maybe it should be its own issue or maybe not?)
When such an interactive program is run, it doesn't show up in the interface, only in the logs. So it is hard to tell what went wrong from just the interface. Here is an example where a git-push command was run:
09:02:17 - opendevin:INFO: codeact_agent.py:279 - Cost: 0.04 USD | Accumulated Cost: 0.43 USD
09:02:17 - ACTION
**CmdRunAction**
THOUGHT:The changes have been successfully committed. Now, I will push the new branch `add-development-link` to the GitHub repository.
COMMAND:
git push origin add-development-link
The interface does not show this "git push".
This issue is stale because it has been open for 30 days with no activity. Remove stale label or comment or this will be closed in 7 days.
This is much much better after https://github.com/OpenDevin/OpenDevin/pull/2034 so I'm OK with closing this.