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

feat(deps): bump supported LangChain package versions to latest #45

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

vnord
Copy link

@vnord vnord commented Mar 9, 2025

Add script to run the test suite against the lowest supported versions

Comment on lines +17 to +19
langchain = ">=0.2.10,<0.4.0"
langchain-core = ">=0.2.43,<0.4.0"
langchain-community = ">=0.2.5,<0.4.0"
Copy link
Author

Choose a reason for hiding this comment

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

Diff via

poetry add "langchain>=0.2.10,<0.4.0" "langchain-core>=0.2.43,<0.4.0" "langchain-community>=0.2.5,<0.4.0"

(and poetry add --group dev "langchain-openai>=0.1.25,<0.4.0"below)

Comment on lines +96 to +97
# 6. Restore original dependencies
print_heading "6. Restoring dependencies"
poetry run pip install -r requirements.bak.txt --quiet
rm requirements.bak.txt
Copy link
Author

Choose a reason for hiding this comment

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

This isn't necessary in the CI -- we could conditionally disable this if we want to save a few seconds.

poetry.lock Outdated
Copy link
Author

Choose a reason for hiding this comment

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

This entire diff comes from https://github.com/lakeraai/chainguard/pull/45/files#r1986414521

This is my first exposure to poetry, so I may have done this incorrectly -- please let me know if that's the case

@@ -0,0 +1,112 @@
#!/usr/bin/env bash
Copy link
Author

Choose a reason for hiding this comment

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

I thought this would be the simplest way to achieve confidence that the rest of the diff isn't breaking.

langchain = "^0.2.10"
langchain-core = "^0.2.22"
langchain = ">=0.2.10,<0.4.0"
langchain-core = ">=0.2.43,<0.4.0"
Copy link
Author

@vnord vnord Mar 9, 2025

Choose a reason for hiding this comment

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

The lower bound was slightly raised here, as I got dependency conflicts when using original version. It's just a patch bump, though, so it shouldn't be breaking.

@vnord vnord force-pushed the upgrade-langchain branch 2 times, most recently from 53cb321 to 5b4b9d4 Compare March 9, 2025 21:49
Add compatibility test script to verify functionality across different LangChain versions
@vnord vnord force-pushed the upgrade-langchain branch from 5b4b9d4 to 29035f5 Compare March 9, 2025 21:51
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