Skip to content

Commit

Permalink
openai: fix low timeouts (#926)
Browse files Browse the repository at this point in the history
  • Loading branch information
theomonnom authored Oct 16, 2024
1 parent d15eb4d commit feb513f
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 10 deletions.
5 changes: 5 additions & 0 deletions .changeset/short-boxes-smoke.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"livekit-plugins-openai": patch
---

openai: fix low timeouts
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ jobs:
- name: Install ffmpeg (macOS)
if: ${{ matrix.platform == 'macos' }}
run: brew update && brew install ffmpeg
run: brew install ffmpeg

- name: Install ffmpeg (Windows)
if: ${{ matrix.platform == 'windows' }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,11 @@ def __init__(
api_key=api_key,
base_url=base_url,
http_client=httpx.AsyncClient(
timeout=httpx.Timeout(timeout=30, connect=10, read=5, pool=5),
timeout=httpx.Timeout(connect=15.0, read=5.0, write=5.0, pool=5.0),
follow_redirects=True,
limits=httpx.Limits(
max_connections=1000,
max_keepalive_connections=100,
max_connections=50,
max_keepalive_connections=50,
keepalive_expiry=120,
),
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,11 @@ def __init__(
api_key=api_key,
base_url=base_url,
http_client=httpx.AsyncClient(
timeout=5.0,
timeout=httpx.Timeout(connect=15.0, read=5.0, write=5.0, pool=5.0),
follow_redirects=True,
limits=httpx.Limits(
max_connections=1000,
max_keepalive_connections=100,
max_connections=50,
max_keepalive_connections=50,
keepalive_expiry=120,
),
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,11 @@ def __init__(
api_key=api_key,
base_url=base_url,
http_client=httpx.AsyncClient(
timeout=5.0,
timeout=httpx.Timeout(connect=15.0, read=5.0, write=5.0, pool=5.0),
follow_redirects=True,
limits=httpx.Limits(
max_connections=1000,
max_keepalive_connections=100,
max_connections=50,
max_keepalive_connections=50,
keepalive_expiry=120,
),
),
Expand Down

0 comments on commit feb513f

Please sign in to comment.