Make sandbox api key configurable via user settings (#8803)

Co-authored-by: openhands <openhands@all-hands.dev>
This commit is contained in:
Rohit Malhotra
2025-06-23 11:25:10 -04:00
committed by GitHub
parent 9b4ad4e6e3
commit bba62c26fd
3 changed files with 4 additions and 0 deletions

View File

@@ -133,6 +133,8 @@ class Session:
default_llm_config.api_key = settings.llm_api_key
default_llm_config.base_url = settings.llm_base_url
self.config.search_api_key = settings.search_api_key
if settings.sandbox_api_key:
self.config.sandbox.api_key = settings.sandbox_api_key.get_secret_value()
# NOTE: this need to happen AFTER the config is updated with the search_api_key
self.config.mcp = settings.mcp_config or MCPConfig(