Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AsyncClient.__init__() got an unexpected keyword argument 'proxies' #1190

Closed
aphafzal opened this issue Nov 29, 2024 · 16 comments
Closed

AsyncClient.__init__() got an unexpected keyword argument 'proxies' #1190

aphafzal opened this issue Nov 29, 2024 · 16 comments
Labels
bug Something isn't working

Comments

@aphafzal
Copy link

aphafzal commented Nov 29, 2024

I've randomly started getting this error from miday yesterday, anyone else facing this issue?

##full error##
Error
There was an error generating a response. Chat history can't be saved at this time. AsyncClient.init() got an unexpected keyword argument 'proxies'

Fix: updating Openai to 1.55.3 in the requirements file fixed the issue.

@aphafzal aphafzal added the bug Something isn't working label Nov 29, 2024
@craigpay
Copy link

I've been getting the same issue today on new web app deployments. Have Microsoft updated web apps again?

@MehmetStead
Copy link

MehmetStead commented Nov 30, 2024

@aphafzal we deployed using azure data studio, (foundry) dont have a repository, how did you update the openai dependency in requirements,txt to 1.55.3 and redeploy, I would need to do that using the kudu console, withuot a repository. Also the version I have is newer 1.6.1, but I am still getting this error. really frustrating that the off the shelf solution of microsoft is buggy.

@ragemnky
Copy link

ragemnky commented Dec 2, 2024

@MehmetStead , I also had a deployment from azure data studio, had to do the following to get it going:

  • Copied requirements.txt to /home/site/wwwroot/
  • Updated openai in requirements.txt to 1.55.3
  • Updated the startup command against the app service to be:

pip install -r /home/site/wwwroot/requirements.txt && python3 -m gunicorn app:app

  • Restarted app service
  • Working again

@r0hitacharya
Copy link

I am using Meta-Llama-3.1-70b-Instruct and still get the same error

@MehmetStead
Copy link

MehmetStead commented Dec 2, 2024

@MehmetStead , I also had a deployment from azure data studio, had to do the following to get it going:

  • Copied requirements.txt to /home/site/wwwroot/
  • Updated openai in requirements.txt to 1.55.3
  • Updated the startup command against the app service to be:

pip install -r /home/site/wwwroot/requirements.txt && python3 -m gunicorn app:app

  • Restarted app service
  • Working again

@ragemnky thanks so much but I found a better way. just fork the repository. Go to your app service, deployment center, disconnect the external git source, and add your own forked repository as the new source. Make sure to select "app service build service" as deployment provider, that creates a web hook in your repository, now when you push, the app will be deployed automatically to your app service, great, no need for a deployment pipeline, or github workflow, or setting any environment variables. You can maintain the code from your own repository, so it really is a click ops solution that works. I am impressed

mlh-csis added a commit to CSIS/basic-rag-bot that referenced this issue Dec 2, 2024
@vleon-align
Copy link

Hi everyone,

I also deployed my app using Azure Data Studio (Foundry) and have tried several solutions, but I’m still facing the same error:

I added the requirements.txt file to the /home/site/wwwroot/ directory and installed the dependencies correctly.
I tried @MehmetStead solution: I forked the repository, set my App Service to use that forked repository as the source in Deployment Center, disconnected the previous external Git source, and selected "App Service Build Service" as the deployment provider.
Despite these steps, I’m still encountering the same error.

Does anyone have any additional suggestions for what else I can try?

@himwroteCode
Copy link

Hi, I deployed from Azure Open AI or Azure Ai Studio and I am getting the same error "AsyncClient.init() got an unexpected keyword argument 'proxies'". Since I followed the no code method so how I resolve this?

Image

@ajallooeian
Copy link

Same issue here. I am using openai 1.9.0 and do now want to downgrade to 1.55.3.

@MehmetStead
Copy link

MehmetStead commented Dec 3, 2024

Hi everyone,

I also deployed my app using Azure Data Studio (Foundry) and have tried several solutions, but I’m still facing the same error:

I added the requirements.txt file to the /home/site/wwwroot/ directory and installed the dependencies correctly. I tried @MehmetStead solution: I forked the repository, set my App Service to use that forked repository as the source in Deployment Center, disconnected the previous external Git source, and selected "App Service Build Service" as the deployment provider. Despite these steps, I’m still encountering the same error.

Does anyone have any additional suggestions for what else I can try?

@vleon-align You have to update python openai dependency to 1.55.3 in requirements and commit

@aphafzal
Copy link
Author

aphafzal commented Dec 3, 2024

@ajallooeian
Openai versioning is a bit confusing, you'll still be upgrading not downgrading.
openai 1.9.0 release date: 21/01/2024
openai 1.55.3 release date : 02/12/2024

@MehmetStead
Copy link

MehmetStead commented Dec 3, 2024

Same issue here. I am using openai 1.9.0 and do now want to downgrade to 1.55.3.

You are not downgrading check openai releases, the numbering is weird 1.55.3 is higher

@NoSkillGuy
Copy link

same issue, upgrading to 1.55.3 worked

@vleon-align
Copy link

Hi everyone,
I also deployed my app using Azure Data Studio (Foundry) and have tried several solutions, but I’m still facing the same error:
I added the requirements.txt file to the /home/site/wwwroot/ directory and installed the dependencies correctly. I tried @MehmetStead solution: I forked the repository, set my App Service to use that forked repository as the source in Deployment Center, disconnected the previous external Git source, and selected "App Service Build Service" as the deployment provider. Despite these steps, I’m still encountering the same error.
Does anyone have any additional suggestions for what else I can try?

@vleon-align You have to update python openai dependency to 1.55.3 in requirements and commit

Thanks a lot @MehmetStead I changed to 1.55.3 and then commit and it works!

@sarah-widder
Copy link
Contributor

Fixed with #1195

@himwroteCode
Copy link

himwroteCode commented Dec 4, 2024

@MehmetStead , I also had a deployment from azure data studio, had to do the following to get it going:

  • Copied requirements.txt to /home/site/wwwroot/
  • Updated openai in requirements.txt to 1.55.3
  • Updated the startup command against the app service to be:

pip install -r /home/site/wwwroot/requirements.txt && python3 -m gunicorn app:app

  • Restarted app service
  • Working again

@ragemnky thanks so much but I found a better way. just fork the repository. Go to your app service, deployment center, disconnect the external git source, and add your own forked repository as the new source. Make sure to select "app service build service" as deployment provider, that creates a web hook in your repository, now when you push, the app will be deployed automatically to your app service, great, no need for a deployment pipeline, or github workflow, or setting any environment variables. You can maintain the code from your own repository, so it really is a click ops solution that works. I am impressed

Hi @MehmetStead this was really helpful, after all workaround I find working. Thanks for the support.

@tahsinalamin
Copy link

Updating openai to 1.55.3 worked!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests