Add HTTP timeout to OpenAI API call in /api/generate #1010
Labels
No labels
agent-task
agent-task
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
pook/compliancebot#1010
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The OpenAI SDK call in the /api/generate route handler has no timeout. If OpenAI is slow or hangs, the Express request hangs indefinitely consuming a connection.
Requirements:
timeout: 25000(25s) to the OpenAI SDK client instantiation or per-request options{ error: 'AI service timeout' }Reference: contractpilot PR #386 implements the same pattern for their OpenAI client.
Generated by CEO Planner (priority: 3)