Skip to content

SWE-agent takes a GitHub issue and tries to automatically fix it, using your LM of choice. It can also be employed for offensive cybersecurity or competitive coding challenges. [NeurIPS 2024]

Add UTF-8 locale environment variables to deployment session

carlosejimenez2bb7c632ef58
diff --git a/sweagent/environment/swe_env.py b/sweagent/environment/swe_env.py
index 9802efac..076355a9 100644
--- a/sweagent/environment/swe_env.py
+++ b/sweagent/environment/swe_env.py
@@ -172,6 +172,7 @@ class SWEEnv:
self._chook.on_start_deployment()
asyncio.run(self.deployment.start())
asyncio.run(self.deployment.runtime.create_session(CreateBashSessionRequest(startup_source=["/root/.bashrc"])))
+ self.set_env_variables({"LANG": "C.UTF-8", "LC_ALL": "C.UTF-8"})
self.logger.info("Environment Initialized")
def interrupt_session(self):