Skip to content

Commit 87084ed

Browse files
authored
fix(timeouts): increased timeouts for function execution & agent (#2256)
1 parent 99e0b81 commit 87084ed

File tree

4 files changed

+4
-18
lines changed

4 files changed

+4
-18
lines changed

apps/sim/executor/constants.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,8 @@ export const HTTP = {
158158

159159
export const AGENT = {
160160
DEFAULT_MODEL: 'claude-sonnet-4-5',
161-
DEFAULT_FUNCTION_TIMEOUT: 5000,
162-
REQUEST_TIMEOUT: 120000,
161+
DEFAULT_FUNCTION_TIMEOUT: 600000, // 10 minutes for custom tool code execution
162+
REQUEST_TIMEOUT: 600000, // 10 minutes for LLM API requests
163163
CUSTOM_TOOL_PREFIX: 'custom_',
164164
} as const
165165

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
11
/**
22
* Execution timeout constants
33
*
4-
* These constants define the timeout values for code execution.
5-
* - DEFAULT_EXECUTION_TIMEOUT_MS: The default timeout for executing user code (3 minutes)
6-
* - MAX_EXECUTION_DURATION: The maximum duration for the API route (adds 30s buffer for overhead)
4+
* DEFAULT_EXECUTION_TIMEOUT_MS: The default timeout for executing user code (10 minutes)
75
*/
86

9-
export const DEFAULT_EXECUTION_TIMEOUT_MS = 180000 // 3 minutes (180 seconds)
10-
export const MAX_EXECUTION_DURATION = 210 // 3.5 minutes (210 seconds) - includes buffer for sandbox creation
7+
export const DEFAULT_EXECUTION_TIMEOUT_MS = 600000 // 10 minutes (600 seconds)

apps/sim/tools/http/request.ts

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -40,15 +40,6 @@ export const requestTool: ToolConfig<RequestParams, RequestResponse> = {
4040
type: 'object',
4141
description: 'Form data to send (will set appropriate Content-Type)',
4242
},
43-
timeout: {
44-
type: 'number',
45-
default: 10000,
46-
description: 'Request timeout in milliseconds',
47-
},
48-
validateStatus: {
49-
type: 'object',
50-
description: 'Custom status validation function',
51-
},
5243
},
5344

5445
request: {

apps/sim/tools/http/types.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@ export interface RequestParams {
88
params?: TableRow[]
99
pathParams?: Record<string, string>
1010
formData?: Record<string, string | Blob>
11-
timeout?: number
12-
validateStatus?: (status: number) => boolean
1311
}
1412

1513
export interface RequestResponse extends ToolResponse {

0 commit comments

Comments
 (0)