Skip to content

fix: resolve langchain dependency conflicts and improve setup instructions#202

Merged
dmpantiu merged 1 commit intomainfrom
fix/setup-deps-and-docs
Mar 27, 2026
Merged

fix: resolve langchain dependency conflicts and improve setup instructions#202
dmpantiu merged 1 commit intomainfrom
fix/setup-deps-and-docs

Conversation

@koldunovn
Copy link
Copy Markdown
Collaborator

Summary

  • Removed langchain-classic from pip dependencies in environment.yml — it requires langchain-core>=1.2.19 which overwrites the conda-installed langchain-core<1.0.0 and breaks langchain 0.3.x, langchain-openai, and langchain-experimental. The package is only used as a fallback import (except ImportError), so the conda-provided langchain already covers it.
  • Pinned langchain-anthropic<1.0.0 to keep it compatible with the 0.3.x LangChain ecosystem.
  • Reordered README setup steps so npm install runs before uvicorn --reload, preventing uvicorn's file watcher from detecting node_modules/ creation and triggering a restart that causes ETIMEDOUT proxy errors in the frontend.
  • Added --reload-exclude 'frontend/node_modules/*' to the uvicorn command as a safety net.

Test plan

  • Run micromamba env create -f environment.yml from scratch — no dependency conflict errors
  • Follow README steps in order — no ETIMEDOUT errors on frontend startup
  • Verify import langchain and import langchain_anthropic work in the created environment

…tions

- Remove langchain-classic from pip deps (requires langchain-core>=1.2.19,
  conflicts with conda langchain 0.3.x; only used as fallback import)
- Pin langchain-anthropic<1.0.0 to stay compatible with langchain-core<1.0.0
- Move npm install before uvicorn start to prevent reload-triggered ETIMEDOUT
- Add --reload-exclude for frontend/node_modules to uvicorn command
Copy link
Copy Markdown
Collaborator

@dmpantiu dmpantiu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Note: pyproject.toml and requirements.txt still list langchain-classic — consider updating those for consistency in a follow-up.

@dmpantiu dmpantiu merged commit cc49b10 into main Mar 27, 2026
4 checks passed
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