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

Openai error "ModuleNotFoundError: No module named 'openai.error'" #46

Open
AbelBlossom opened this issue Dec 3, 2023 · 4 comments
Open

Comments

@AbelBlossom
Copy link

When running python main.py --targetlang nodejs I go this errror

Traceback (most recent call last):
  File "/Users/mac/Desktop/dev/abel/gpt-migrate/gpt_migrate/main.py", line 7, in <module>
    from ai import AI
  File "/Users/mac/Desktop/dev/abel/gpt-migrate/gpt_migrate/ai.py", line 6, in <module>
    from litellm import completion
  File "/Users/mac/Desktop/dev/abel/gpt-migrate/gpt_migrate/env/lib/python3.11/site-packages/litellm/__init__.py", line 28, in <module>
    from .timeout import timeout
  File "/Users/mac/Desktop/dev/abel/gpt-migrate/gpt_migrate/env/lib/python3.11/site-packages/litellm/timeout.py", line 11, in <module>
    from openai.error import Timeout
ModuleNotFoundError: No module named 'openai.error'
@AbelBlossom AbelBlossom changed the title Openai error when on start Openai error "ModuleNotFoundError: No module named 'openai.error'" Dec 3, 2023
@DrSharky
Copy link

I also ran into this problem.

@prestonator
Copy link

Did you ever find a fix? @DrSharky @AbelBlossom

@superkido511
Copy link

I fixed it by downgrading openai to 0.28.1. It not perfect but work so far

@azad-resolver
Copy link

I fixed it by downgrading openai to 0.28.1. It not perfect but work so far

Thanks, that fixed it for me!

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

No branches or pull requests

5 participants