Hello, and sorry for opening the issue here but did not find a better place.
! pip install ibm-watsonx-ai
python -c "from ibm_watsonx_ai.foundation_models import ModelInference"
Traceback (most recent call last):
File "<string>", line 1, in <module>
from ibm_watsonx_ai.foundation_models import ModelInference
File "/redacted/python3.14/site-packages/ibm_watsonx_ai/foundation_models/__init__.py", line 6, in <module>
from ibm_watsonx_ai.foundation_models.embeddings import Embeddings
File "/redacted/python3.14/site-packages/ibm_watsonx_ai/foundation_models/embeddings/__init__.py", line 7, in <module>
from .embeddings import Embeddings
File "/redacted/python3.14/site-packages/ibm_watsonx_ai/foundation_models/embeddings/embeddings.py", line 26, in <module>
from ibm_watsonx_ai.foundation_models.schema import BaseSchema, Crypto
File "/redacted/python3.14/site-packages/ibm_watsonx_ai/foundation_models/schema/__init__.py", line 6, in <module>
from ibm_watsonx_ai.foundation_models.schema._api import * # noqa: F403
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/redacted/python3.14/site-packages/ibm_watsonx_ai/foundation_models/schema/_api.py", line 114, in <module>
class TextGenDecodingMethod(StrEnum):
GREEDY = "greedy"
SAMPLE = "sample"
File "/redacted/python3.14/enum.py", line 549, in __new__
enum_class = super().__new__(metacls, cls, bases, classdict, **kwds)
File "/redacted/python3.14/enum.py", line 271, in __set_name__
enum_member.__init__(*args)
~~~~~~~~~~~~~~~~~~~~^^^^^^^
File "/redacted/python3.14/site-packages/ibm_watsonx_ai/utils/utils.py", line 1182, in __init__
super().__init__(*args, **kwargs)
~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
TypeError: object.__init__() takes exactly one argument (the instance to initialize)
Hello, and sorry for opening the issue here but did not find a better place.
ibm-watsonx-aifails to import on Python 3.14 due to the removal ofEnum.__init__in CPython (python/cpython#128081).Example
Error