Hi,
I'm a bit confused. I'm having this openai error in pythonanywhere console. But the same virtualenv (same python 3.10) and repo is working locally and working on render.com.
So I'm guessing there is a specific case in pythonanywhere? How to go about this?
==============
Traceback (most recent call last):
File "/home/bentraje/bentraje-api/app.py", line 4, in <module>
from openai import OpenAI
File "/home/bentraje/.local/lib/python3.10/site-packages/openai/__init__.py", line 8, in <module>
from . import types
File "/home/bentraje/.local/lib/python3.10/site-packages/openai/types/__init__.py", line 5, in <module>
from .batch import Batch as Batch
File "/home/bentraje/.local/lib/python3.10/site-packages/openai/types/batch.py", line 7, in <module>
from .._models import BaseModel
File "/home/bentraje/.local/lib/python3.10/site-packages/openai/_models.py", line 736, in <module>
class RootModel(GenericModel, Generic[_T]):
File "pydantic/main.py", line 187, in pydantic.main.ModelMetaclass.__new__
File "pydantic/typing.py", line 356, in pydantic.typing.resolve_annotations
File "/usr/local/lib/python3.10/typing.py", line 327, in _eval_type
return t._evaluate(globalns, localns, recursive_guard)
File "/usr/local/lib/python3.10/typing.py", line 693, in _evaluate
type_ = _type_check(
File "/usr/local/lib/python3.10/typing.py", line 176, in _type_check
raise TypeError(f"{msg} Got {arg!r:.100}.")
TypeError: Forward references must evaluate to types. Got ~_T.