Skip to content

Pin LangChain version to less than 1.0 - #168

Merged
Yuge Zhang (ultmaster) merged 1 commit into
mainfrom
pin-langchain-version
Oct 18, 2025
Merged

Pin LangChain version to less than 1.0#168
Yuge Zhang (ultmaster) merged 1 commit into
mainfrom
pin-langchain-version

Conversation

@ultmaster

Copy link
Copy Markdown
Contributor

LangChain 1.0 has been released. It has broken many of our usages like AgentExecutor, langchain.hub, tool, create_react_agent. Due to the documentation is still under construction, I cannot easily find substitutes that I'm sure will work well.

So let's pin langchain for now and wait for upstream to be more mature.

Copilot AI review requested due to automatic review settings October 18, 2025 02:47

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull Request Overview

This PR pins LangChain-related dependencies to versions less than 1.0 to avoid breaking changes introduced in the LangChain 1.0 release. The PR addresses compatibility issues with features like AgentExecutor, langchain.hub, tool, and create_react_agent by constraining package versions until upstream documentation and migration paths are more mature.

Key Changes:

  • Version constraints added to LangChain ecosystem packages
  • Import path updated to use langchain_core for callback handlers

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
pyproject.toml Added version constraints <1.0 to langgraph, langchain[openai], and langchain-text-splitters dependencies
agentlightning/tracer/base.py Updated import path from langchain.callbacks.base to langchain_core.callbacks.base for better compatibility

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment thread pyproject.toml
"langchain[openai]",
"langgraph<1.0",
"langchain[openai]<1.0",
"langchain-community",

Copilot AI Oct 18, 2025

Copy link

Choose a reason for hiding this comment

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

The langchain-community package should also be pinned to <1.0 for consistency with other LangChain packages. LangChain 1.0 includes breaking changes across the ecosystem, and langchain-community is part of this ecosystem.

Suggested change
"langchain-community",
"langchain-community<1.0",

Copilot uses AI. Check for mistakes.
@ultmaster
Yuge Zhang (ultmaster) merged commit d31090e into main Oct 18, 2025
14 checks passed
@ultmaster
Yuge Zhang (ultmaster) deleted the pin-langchain-version branch October 28, 2025 01:23
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