We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fcaead7 commit 888958aCopy full SHA for 888958a
aworld/sandbox/tool_servers/terminal/src/terminal.py
@@ -182,6 +182,14 @@ async def run_code(
182
if isinstance(output_format, FieldInfo):
183
output_format = output_format.default
184
185
+ # Timeout: env TERMINAL_TIMEOUT overrides parameter/default when set
186
+ env_timeout = os.environ.get("TERMINAL_TIMEOUT")
187
+ if env_timeout is not None:
188
+ try:
189
+ timeout = int(env_timeout)
190
+ except ValueError:
191
+ pass # keep current timeout if env value is not a valid integer
192
+
193
output_data = ""
194
command_id = str(uuid.uuid4())
195
try:
0 commit comments