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

Update pyproject.toml to fix startup error #991

Merged
merged 1 commit into from
Dec 20, 2024

Conversation

AndreaGirlando
Copy link
Contributor

Bug Description

When the application starts, it throws the following error:

cheshire_cat_core  |   File "/app/cat/looking_glass/cheshire_cat.py", line 145, in load_language_model
cheshire_cat_core  |     llm = FactoryClass.get_llm_from_config(selected_llm_config["value"])
cheshire_cat_core  |   File "/app/cat/factory/llm.py", line 35, in get_llm_from_config
cheshire_cat_core  |     return cls._pyclass.default(**config)
cheshire_cat_core  |   File "/usr/local/lib/python3.10/site-packages/langchain_core/load/serializable.py", line 113, in __init__
cheshire_cat_core  |     super().__init__(*args, **kwargs)
cheshire_cat_core  |   File "/usr/local/lib/python3.10/site-packages/pydantic/v1/main.py", line 341, in __init__
cheshire_cat_core  |     raise validation_error
cheshire_cat_core  | pydantic.v1.error_wrappers.ValidationError: 1 validation error for ChatOpenAI
cheshire_cat_core  | __root__
cheshire_cat_core  |   Client.__init__() got an unexpected keyword argument 'proxies' (type=type_error)

Steps to Reproduce

  1. Clone the repository.
  2. Start the application using docker compose up.
  3. Modify the embedding model settings.
  4. Restart the application.
  5. The error described above will appear during startup.

Solution

The issue was caused by an unsupported proxies argument during the initialization process, likely due to a library compatibility problem.

The problem has been resolved by locking the httpx version to 0.27.2, as suggested in this issue discussion, ensuring the application starts without errors.


Expected Behavior

The application should now start successfully, even after changing the embedding model settings.


Fix startup error caused by unsupported 'proxies' argument
@pieroit pieroit merged commit ca6a1aa into cheshire-cat-ai:main Dec 20, 2024
2 checks passed
@pieroit
Copy link
Member

pieroit commented Dec 20, 2024

Always a good idea to fix dependencies version. Thanks @AndreaGirlando

@pieroit
Copy link
Member

pieroit commented Dec 20, 2024

P.S. next time PR on develop

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

Successfully merging this pull request may close these issues.

2 participants