Skip to content

Commit

Permalink
Update action_execution_server.py
Browse files Browse the repository at this point in the history
  • Loading branch information
SmartManoj committed Nov 6, 2024
1 parent ef83707 commit 6eab6e3
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion openhands/runtime/action_execution_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,11 @@ async def run_ipython(self, action: IPythonRunCellAction) -> Observation:
obs: Observation = ErrorObservation(
"[The content in this file is absolutely correct. Also, you can't modify this test file. You must pass this test case. You should correct the codebase instead.]"
)
elif action.code == self.last_code and self.is_last_code_error:
elif (
(os.getenv('SWE_BENCH') == '1' or 1)
and action.code == self.last_code
and self.is_last_code_error
):
obs = ErrorObservation(
'[You are trying to run the same code twice. Please focus and run the correct code.]'
)
Expand Down

0 comments on commit 6eab6e3

Please sign in to comment.