Skip to content

fix(deps): upgrade langchain ecosystem to 1.x#477

Open
hbrodin wants to merge 2 commits intomainfrom
fix/dependabot-langchain-langgraph-upgrades
Open

fix(deps): upgrade langchain ecosystem to 1.x#477
hbrodin wants to merge 2 commits intomainfrom
fix/dependabot-langchain-langgraph-upgrades

Conversation

@hbrodin
Copy link
Collaborator

@hbrodin hbrodin commented Mar 3, 2026

Summary

  • Upgrade the LangChain/LangGraph ecosystem to 1.x to fix CVE-2026-27794 (langgraph-checkpoint deserialization RCE, medium) and CVE-2026-26013 (langchain-core SSRF, low)
  • Upgrade langfuse 2.x -> 3.x for langchain 1.x compatibility
  • Bump pydantic-settings 2.7.x -> 2.10.x (required by langchain-community 0.4.x)
  • Update openlit constraint to >=1.36.8 (ToolNode fix landed in fix(langgraph): prevent wrapping of ToolNode objects openlit/openlit#991) with uv override for their stale langchain<0.4.0 pin
  • Fix two import paths broken by langchain 1.x (langchain.callbacks.base -> langchain_core.callbacks, langchain.prompts -> langchain_core.prompts)
  • Move langfuse to common[full] optional dep to avoid protobuf conflict with fuzzer_runner's OSS-Fuzz protobuf==3.20.3 constraint

Dependabot alert #88 (protobuf CVE in fuzzer_runner) is not addressed — it's pinned to 3.20.3 for OSS-Fuzz compatibility and the vulnerable JSON parsing feature is not used.

Test plan

  • All 7 lockfiles resolve successfully
  • Tests pass across all components (failures are pre-existing Redis connection errors, not related to this change)
  • No langchain/langgraph/langfuse import errors
  • Verify patcher agent works end-to-end with langgraph 1.x (deprecation warning on create_react_agent — functional but should migrate to langchain.agents.create_agent in a follow-up)

🤖 Generated with Claude Code

Upgrade the LangChain/LangGraph ecosystem to address CVE-2026-27794
(langgraph-checkpoint deserialization RCE) and CVE-2026-26013
(langchain-core SSRF in token counting).

Package upgrades:
- langchain-core: 0.3.x -> 1.2.17
- langchain: 0.3.x -> 1.2.10
- langchain-openai: 0.3.x -> 1.1.9
- langchain-community: 0.3.x -> 0.4.1
- langgraph: 0.6.x -> 1.0.10
- langgraph-checkpoint: 3.x -> 4.0.1
- langfuse: 2.59.x -> 3.14.5
- pydantic-settings: 2.7.x -> 2.10.1
- openlit: <1.36.6 -> >=1.36.8 (ToolNode fix in PR #991)
- openai: 1.100.x -> 1.109.x (patcher)

Code changes:
- common/llm.py: Update imports for langchain 1.x and langfuse 3.x
- seed-gen/task.py: Use langchain_core.prompts instead of langchain.prompts
- Move langfuse to common[full] optional dep (avoids protobuf conflict
  with fuzzer_runner's OSS-Fuzz protobuf==3.20.3 constraint)
- Add uv override-dependencies for openlit's stale langchain<0.4.0 pin

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@hbrodin hbrodin marked this pull request as draft March 3, 2026 12:24
- common/llm.py: Remove secret_key and host args from langfuse 3.x
  CallbackHandler (reads from env vars automatically via get_client)
- seed-gen/task.py: Fix import sort order after langchain_core.prompts move

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@hbrodin
Copy link
Collaborator Author

hbrodin commented Mar 3, 2026

I tested with libpng and the correct patch seems to be generated.

@hbrodin hbrodin marked this pull request as ready for review March 3, 2026 13: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.

1 participant