mishl-dev / Discord-AI-Chatbot

This Discord chatbot is incredibly versatile. Powered incredibly fast Groq API
GNU Affero General Public License v3.0
1.32k stars 417 forks source link

Since new update can't start main.py #244

Closed Donixon closed 11 months ago

Donixon commented 11 months ago

Hi all! It seems that I \can't start the bot anymore since a week. Worked like a charm before. Error getting:

Z:\discordbot> python .\main.py    
Traceback (most recent call last):
  File "Z:\discordbot\main.py", line 17, in <module>
    from bot_utilities.ai_utils import generate_response, generate_image_prodia, search, poly_image_gen, generate_gpt4_response, dall_e_gen, sdxl
  File "Z:\discordbot\bot_utilities\ai_utils.py", line 11, in <module>
    from openai import AsyncOpenAI
ImportError: cannot import name 'AsyncOpenAI' from 'openai' (C:\Users\****\anaconda3\Lib\site-packages\openai\__init__.py)

Installed all requirments.txt, everything installed correct and newest version. Not sure why?

Hopefully someone can help me get the bot up and running again.

KingsRequin commented 11 months ago

Just do: pip install --upgrade openai

Donixon commented 11 months ago

Tried this local and it works, thanks! The problem was that I run the bot in Docker. Build the container, new, and fixt. Thanks!