cartesia-ai / cartesia-python

The official Python library for the Cartesia API
https://pypi.org/project/cartesia/
MIT License
30 stars 4 forks source link

[CAR-405] Fixing Async + Websocket Issues #36

Closed chongzluong closed 5 months ago

chongzluong commented 5 months ago

Ticket: https://linear.app/cartesia/issue/CAR-405/[python-client]-async-websocket-issues

Seems like we might be running into some issues related to interruptions or the like? I think the suggesiton was that when an async client makes subsequent requests to the server, we sometimes get issues with long sequences suggesting that there might be an issue with how we're handling the web socket.

However in practice I appear to be unable to reproduce this behavior.

A few changes here:

linear[bot] commented 5 months ago
CAR-405 [Python Client] Async + Websocket Issues

Per conversation with kavan.doctor: Might be a small bug in how web socket handles async. What we think is happening: * When a client makes a 2nd request to the server, async client makes another generation request * Websocket is not being flushed * Testing might be hard * Launch a long sequence of text - currently we only accept up to 400 characters * Immediately launch another one * Perhaps in repo test

chongzluong commented 5 months ago

The docstring and default fixes seem like good changes. Why don't we get those in anyway and split off the bug investigation? Even if both were complete now, small bite-sized PRs are good

Haha fair enough I'll separate that out

chongzluong commented 5 months ago

Given that we're unable to reproduce, closing this out for now