You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have run into another painful side-effect of not canceling gracefully which is unpredictable/incorrect resource management and release. In my case I pass an httpx client to the sdk to perform the calls to my LLM and I noticed that after some use and cancelled requests, the httpx client exhausts every available connection in the pool leading to every request failing with a PoolTimeout.
I would propose that after_turn is the default value of result.cancel(). If needed I can try to create a minimal reproduction code of the issue I mentioned.
Activity
idzikovski commentedon Jun 15, 2026
I have run into another painful side-effect of not canceling gracefully which is unpredictable/incorrect resource management and release. In my case I pass an httpx client to the sdk to perform the calls to my LLM and I noticed that after some use and cancelled requests, the httpx client exhausts every available connection in the pool leading to every request failing with a PoolTimeout.
I would propose that
after_turnis the default value ofresult.cancel(). If needed I can try to create a minimal reproduction code of the issue I mentioned.