Use AsyncRetry in acompletion_with_retries
Title
This PR fixes the retry mechanism in main.acompletion_with_retries. Although this method is deprecated, it is used in the utils.client.wrapper_async method, which is not marked as deprecated - meaning this should be fixed, or utils.client.wrapper_async should be updated to use main.acompletion or router.acompletion.
Relevant issues
Similar to #4908 however updating utils.client.wrapper_async to use main.acompletion causes unexpected results.
Pre-Submission checklist
Please complete all items before asking a LiteLLM maintainer to review your PR
- [x] I have Added testing in the
tests/litellm/directory, Adding at least 1 test is a hard requirement - see details - [x] I have added a screenshot of my new test passing locally
- [x] My PR passes all unit tests on (
make test-unit)[https://docs.litellm.ai/docs/extras/contributing_code] - [x] My PR's scope is as isolated as possible, it only solves 1 specific problem
Type
🐛 Bug Fix
Changes
The latest updates on your projects. Learn more about Vercel for Git ↗︎
| Name | Status | Preview | Comments | Updated (UTC) |
|---|---|---|---|---|
| litellm | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Mar 14, 2025 6:43pm |
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.