Skip to content
This repository has been archived by the owner on Apr 3, 2024. It is now read-only.

bad import #29

Closed
iplayfast opened this issue Jan 29, 2024 · 2 comments
Closed

bad import #29

iplayfast opened this issue Jan 29, 2024 · 2 comments

Comments

@iplayfast
Copy link

python autocrew.py 
Traceback (most recent call last):
  File "/home/chris/ai/aiprojects/crewai-autocrew/autocrew.py", line 28, in <module>
    from core import AutoCrew
  File "/home/chris/ai/aiprojects/crewai-autocrew/core.py", line 13, in <module>
    from openai import OpenAI
ImportError: cannot import name 'OpenAI' from 'openai' (/home/chris/anaconda3/envs/crewAI/lib/python3.11/site-packages/openai/__init__.py)

from openai import OpenAI should be
import openai

@iplayfast
Copy link
Author

Ah, recent update. For anyone else seeing this, this is the fix:
pip install openai --upgrade

@yanniedog
Copy link
Owner

The core problem was that the script actually wasn't installing dependencies from requirements.txt at all (until the version I've literally just released now: 2.1.5)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants