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

Incompatibility between mistral-common and mistralai from pypi #35

Open
iGherghe opened this issue Aug 8, 2024 · 2 comments
Open

Incompatibility between mistral-common and mistralai from pypi #35

iGherghe opened this issue Aug 8, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@iGherghe
Copy link

iGherghe commented Aug 8, 2024

Python -VV

Python 3.12.4 | packaged by Anaconda, Inc. | (main, Jun 18 2024, 15:12:24) [GCC 11.2.0]

Pip Freeze

annotated-types==0.7.0
anyio==4.4.0
attrs==24.2.0
certifi==2024.7.4
charset-normalizer==3.3.2
h11==0.14.0
httpcore==1.0.5
httpx==0.27.0
idna==3.7
jsonpath-python==1.0.6
jsonschema==4.21.1
jsonschema-specifications==2023.12.1
mistral_common==1.3.3
mistralai==1.0.0
mypy-extensions==1.0.0
pydantic==2.6.1
pydantic_core==2.16.2
python-dateutil==2.9.0.post0
referencing==0.35.1
regex==2024.7.24
requests==2.32.3
rpds-py==0.20.0
sentencepiece==0.2.0
setuptools==72.1.0
six==1.16.0
sniffio==1.3.1
tiktoken==0.7.0
typing-inspect==0.9.0
typing_extensions==4.12.2
urllib3==2.2.2
wheel==0.43.0

Reproduction Steps

In a fresh conda environment I've tried to install mistralai and mistral-common:

pip install mistralai
pip install mistral-common

First command worked. For the second one I got an error because pydantic from mistral-common is not compatible with the one installed by mistralai:

pip install mistral-common
Collecting mistral-common
  Using cached mistral_common-1.3.3-py3-none-any.whl.metadata (4.1 kB)
Collecting jsonschema==4.21.1 (from mistral-common)
  Using cached jsonschema-4.21.1-py3-none-any.whl.metadata (7.8 kB)
Collecting pydantic==2.6.1 (from mistral-common)
  Using cached pydantic-2.6.1-py3-none-any.whl.metadata (83 kB)
Collecting sentencepiece==0.2.0 (from mistral-common)
  Using cached sentencepiece-0.2.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (7.7 kB)
Collecting tiktoken<0.8.0,>=0.7.0 (from mistral-common)
  Using cached tiktoken-0.7.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (6.6 kB)
Requirement already satisfied: typing-extensions<5.0.0,>=4.11.0 in /home/paul/miniconda3/envs/mistralprompts/lib/python3.12/site-packages (from mistral-common) (4.12.2)
Collecting attrs>=22.2.0 (from jsonschema==4.21.1->mistral-common)
  Using cached attrs-24.2.0-py3-none-any.whl.metadata (11 kB)
Collecting jsonschema-specifications>=2023.03.6 (from jsonschema==4.21.1->mistral-common)
  Using cached jsonschema_specifications-2023.12.1-py3-none-any.whl.metadata (3.0 kB)
Collecting referencing>=0.28.4 (from jsonschema==4.21.1->mistral-common)
  Using cached referencing-0.35.1-py3-none-any.whl.metadata (2.8 kB)
Collecting rpds-py>=0.7.1 (from jsonschema==4.21.1->mistral-common)
  Using cached rpds_py-0.20.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (4.2 kB)
Requirement already satisfied: annotated-types>=0.4.0 in /home/paul/miniconda3/envs/mistralprompts/lib/python3.12/site-packages (from pydantic==2.6.1->mistral-common) (0.7.0)
Collecting pydantic-core==2.16.2 (from pydantic==2.6.1->mistral-common)
  Using cached pydantic_core-2.16.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (6.5 kB)
Collecting regex>=2022.1.18 (from tiktoken<0.8.0,>=0.7.0->mistral-common)
  Using cached regex-2024.7.24-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (40 kB)
Collecting requests>=2.26.0 (from tiktoken<0.8.0,>=0.7.0->mistral-common)
  Using cached requests-2.32.3-py3-none-any.whl.metadata (4.6 kB)
Collecting charset-normalizer<4,>=2 (from requests>=2.26.0->tiktoken<0.8.0,>=0.7.0->mistral-common)
  Using cached charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (33 kB)
Requirement already satisfied: idna<4,>=2.5 in /home/paul/miniconda3/envs/mistralprompts/lib/python3.12/site-packages (from requests>=2.26.0->tiktoken<0.8.0,>=0.7.0->mistral-common) (3.7)
Collecting urllib3<3,>=1.21.1 (from requests>=2.26.0->tiktoken<0.8.0,>=0.7.0->mistral-common)
  Using cached urllib3-2.2.2-py3-none-any.whl.metadata (6.4 kB)
Requirement already satisfied: certifi>=2017.4.17 in /home/paul/miniconda3/envs/mistralprompts/lib/python3.12/site-packages (from requests>=2.26.0->tiktoken<0.8.0,>=0.7.0->mistral-common) (2024.7.4)
Using cached mistral_common-1.3.3-py3-none-any.whl (3.3 MB)
Using cached jsonschema-4.21.1-py3-none-any.whl (85 kB)
Using cached pydantic-2.6.1-py3-none-any.whl (394 kB)
Using cached sentencepiece-0.2.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.3 MB)
Using cached pydantic_core-2.16.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.2 MB)
Using cached tiktoken-0.7.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.1 MB)
Using cached attrs-24.2.0-py3-none-any.whl (63 kB)
Using cached jsonschema_specifications-2023.12.1-py3-none-any.whl (18 kB)
Using cached referencing-0.35.1-py3-none-any.whl (26 kB)
Using cached regex-2024.7.24-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (790 kB)
Using cached requests-2.32.3-py3-none-any.whl (64 kB)
Using cached rpds_py-0.20.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (357 kB)
Using cached charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (141 kB)
Using cached urllib3-2.2.2-py3-none-any.whl (121 kB)
Installing collected packages: sentencepiece, urllib3, rpds-py, regex, pydantic-core, charset-normalizer, attrs, requests, referencing, pydantic, tiktoken, jsonschema-specifications, jsonschema, mistral-common
  Attempting uninstall: pydantic-core
    Found existing installation: pydantic_core 2.20.1
    Uninstalling pydantic_core-2.20.1:
      Successfully uninstalled pydantic_core-2.20.1
  Attempting uninstall: pydantic
    Found existing installation: pydantic 2.8.2
    Uninstalling pydantic-2.8.2:
      Successfully uninstalled pydantic-2.8.2
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
mistralai 1.0.0 requires pydantic<2.9.0,>=2.8.2, but you have pydantic 2.6.1 which is incompatible.
Successfully installed attrs-24.2.0 charset-normalizer-3.3.2 jsonschema-4.21.1 jsonschema-specifications-2023.12.1 mistral-common-1.3.3 pydantic-2.6.1 pydantic-core-2.16.2 referencing-0.35.1 regex-2024.7.24 requests-2.32.3 rpds-py-0.20.0 sentencepiece-0.2.0 tiktoken-0.7.0 urllib3-2.2.2

Expected Behavior

I expect to be able to install both packages without incompatibilities in the same environment

Additional Context

I've tested the above with both Python 3.12 and 3.11 and got same error during installation

Suggested Solutions

No response

@iGherghe iGherghe added the bug Something isn't working label Aug 8, 2024
@patrickvonplaten
Copy link
Contributor

patrickvonplaten commented Aug 15, 2024

Thanks for the issue! #40 should solve it

@patrickvonplaten
Copy link
Contributor

#40 is merged and 1.3.4 is out - let me know if this solves the issue :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants