python3Packages.{langchain,langgraph}: 250730 update (#427212)

This commit is contained in:
Pol Dellaiera 2025-07-31 15:20:51 +02:00 committed by GitHub
commit c0453c2c58
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
11 changed files with 78 additions and 44 deletions

View File

@ -22,14 +22,14 @@
buildPythonPackage rec {
pname = "langchain-anthropic";
version = "0.3.15";
version = "0.3.17";
pyproject = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langchain";
tag = "langchain-anthropic==${version}";
hash = "sha256-GOD6pMuUDCfrQ6MP+/HXZIg5wHUDRysosEjXjewY/9M=";
hash = "sha256-oUT4Mu/vG+bVF6zLQX2RbVUglJ6VMyBt8XtCBSlBlpU=";
};
sourceRoot = "${src.name}/libs/partners/anthropic";

View File

@ -36,14 +36,14 @@
buildPythonPackage rec {
pname = "langchain-core";
version = "0.3.66";
version = "0.3.72";
pyproject = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langchain";
tag = "langchain-core==${version}";
hash = "sha256-k9B2ApNyX3w6RTt/XdOl2FvU87NuZSi96vvfJOnBltM=";
hash = "sha256-Q2uGMiODUtwkPdOyuSqp8vqjlLjiXk75QjXp7rr20tc=";
};
sourceRoot = "${src.name}/libs/core";

View File

@ -22,14 +22,14 @@
buildPythonPackage rec {
pname = "langchain-ollama";
version = "0.3.5";
version = "0.3.6";
pyproject = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langchain";
tag = "langchain-ollama==${version}";
hash = "sha256-UmfbCctAb0D8mETICl5OJ58vghwhQKWkM1drkPt1aAg=";
hash = "sha256-GQkyJaYvwRbjDR0Rfen7/X5hFhY2+WU74B6/9Ufhpo4=";
};
sourceRoot = "${src.name}/libs/partners/ollama";

View File

@ -44,14 +44,14 @@
buildPythonPackage rec {
pname = "langchain";
version = "0.3.26";
version = "0.3.27";
pyproject = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langchain";
tag = "langchain==${version}";
hash = "sha256-xxkayOtC2GtgtF3tPkTGKOS9VQ/y2gRPopvKq48/Kq0=";
hash = "sha256-bqzJ0017Td65rhDCr2wfx+SCaJzPZTFzQpzy3RlaRj4=";
};
sourceRoot = "${src.name}/libs/langchain";
@ -128,6 +128,9 @@ buildPythonPackage rec {
"test_serializable_mapping"
"test_person"
"test_aliases_hidden"
# AssertionError: (failed string match due to terminal control chars in output)
# https://github.com/langchain-ai/langchain/issues/32150
"test_filecallback"
];
disabledTestPaths = [
@ -151,6 +154,8 @@ buildPythonPackage rec {
rev-prefix = "langchain==";
};
__darwinAllowLocalNetworking = true;
meta = {
description = "Building applications with LLMs through composability";
homepage = "https://github.com/langchain-ai/langchain";

View File

@ -5,7 +5,7 @@
stdenvNoCC,
# build system
poetry-core,
hatchling,
# dependencies
langgraph-checkpoint,
@ -26,14 +26,14 @@
buildPythonPackage rec {
pname = "langgraph-checkpoint-postgres";
version = "2.0.21";
version = "2.0.23";
pyproject = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langgraph";
tag = "checkpointpostgres==${version}";
hash = "sha256-hl1EBOtUkSfHGxsM+LOZPLSvkW7hdHS08klpvA7/Bd0=";
hash = "sha256-QAzT8T3bf3R3gwI/iWDYYDz0SxgLZsP61oMk72dYz4s=";
};
postgresqlTestSetupPost = ''
@ -44,7 +44,7 @@ buildPythonPackage rec {
sourceRoot = "${src.name}/libs/checkpoint-postgres";
build-system = [ poetry-core ];
build-system = [ hatchling ];
dependencies = [
langgraph-checkpoint

View File

@ -4,15 +4,17 @@
fetchFromGitHub,
# build system
poetry-core,
hatchling,
# dependencies
aiosqlite,
langgraph-checkpoint,
sqlite-vec,
# testing
pytest-asyncio,
pytestCheckHook,
sqlite,
# passthru
gitUpdater,
@ -20,28 +22,33 @@
buildPythonPackage rec {
pname = "langgraph-checkpoint-sqlite";
version = "2.0.6";
version = "2.0.10";
pyproject = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langgraph";
tag = "checkpointsqlite==${version}";
hash = "sha256-UUlrhQS0C2rPp//+LwU2rgR4R3AM5fM9X3CYvi/DAy8=";
hash = "sha256-570rXAxS4p2b7fc1aqSNArXHTz7G2GjZQDqMlqK7Jso=";
};
sourceRoot = "${src.name}/libs/checkpoint-sqlite";
build-system = [ poetry-core ];
build-system = [ hatchling ];
dependencies = [
aiosqlite
langgraph-checkpoint
sqlite-vec
];
pythonRelaxDeps = [
"aiosqlite"
# Bug: version is showing up as 0.0.0
# https://github.com/NixOS/nixpkgs/issues/427197
"sqlite-vec"
# Checkpoint clients are lagging behind langgraph-checkpoint
"langgraph-checkpoint"
];
@ -51,6 +58,20 @@ buildPythonPackage rec {
nativeCheckInputs = [
pytest-asyncio
pytestCheckHook
sqlite
];
disabledTestPaths = [
# Failed: 'flaky' not found in `markers` configuration option
"tests/test_ttl.py"
];
disabledTests = [
# AssertionError: (fails object comparison due to extra runtime fields)
# https://github.com/langchain-ai/langgraph/issues/5604
"test_combined_metadata"
"test_asearch"
"test_search"
];
passthru.updateScript = gitUpdater {

View File

@ -4,7 +4,7 @@
fetchFromGitHub,
# build system
poetry-core,
hatchling,
# dependencies
langchain-core,
@ -13,6 +13,8 @@
# testing
dataclasses-json,
numpy,
pandas,
pytest-asyncio,
pytest-mock,
pytestCheckHook,
@ -23,19 +25,19 @@
buildPythonPackage rec {
pname = "langgraph-checkpoint";
version = "2.0.26";
version = "2.1.1";
pyproject = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langgraph";
tag = "checkpoint==${version}";
hash = "sha256-DSkjaxUfpsOg2ex0dgfO/UJ7WiQb5wQsAGgHPTckF6o=";
hash = "sha256-UY3AChShKfOrtOQzOm5vi3Yy3rlBc+TAje9L2L6My/U=";
};
sourceRoot = "${src.name}/libs/checkpoint";
build-system = [ poetry-core ];
build-system = [ hatchling ];
dependencies = [
langchain-core
@ -48,6 +50,8 @@ buildPythonPackage rec {
nativeCheckInputs = [
dataclasses-json
numpy
pandas
pytest-asyncio
pytest-mock
pytestCheckHook

View File

@ -5,7 +5,7 @@
fetchFromGitHub,
# build-system
poetry-core,
hatchling,
# dependencies
langchain-core,
@ -21,6 +21,7 @@
pytest-asyncio,
pytest-mock,
pytestCheckHook,
syrupy,
xxhash,
# passthru
@ -30,19 +31,19 @@
# It exists so the langgraph team can iterate on it without having to rebuild langgraph.
buildPythonPackage rec {
pname = "langgraph-prebuilt";
version = "0.1.8";
version = "0.6.1";
pyproject = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langgraph";
tag = "prebuilt==${version}";
hash = "sha256-mYcj7HRbB5H6G0CVLOICKgdtR5Wlv9WeTIBjQJqlhOE=";
hash = "sha256-8mubZSV1CDgYzykKaaWqn04yJldAgdGmgZDm54towWc=";
};
sourceRoot = "${src.name}/libs/prebuilt";
build-system = [ poetry-core ];
build-system = [ hatchling ];
dependencies = [
langchain-core
@ -66,6 +67,7 @@ buildPythonPackage rec {
pytest-asyncio
pytest-mock
pytestCheckHook
syrupy
xxhash
];
@ -82,6 +84,9 @@ buildPythonPackage rec {
# psycopg.OperationalError: connection failed: connection to server at "127.0.0.1", port 5442 failed: Connection refused
# Is the server running on that host and accepting TCP/IP connections?
"tests/test_react_agent.py"
# Utilities to import
"tests/conftest.py"
];
passthru.updateScript = gitUpdater {

View File

@ -4,7 +4,7 @@
fetchFromGitHub,
# build-system
poetry-core,
hatchling,
# dependencies
httpx,
@ -18,19 +18,19 @@
buildPythonPackage rec {
pname = "langgraph-sdk";
version = "0.1.69";
version = "0.2.0";
pyproject = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langgraph";
tag = "sdk==${version}";
hash = "sha256-MRs5crbUEak/fr17+lerGFY+xTm7sanUW1lZXbPBAeg=";
hash = "sha256-uhVdtB/fLy0hfZKfzNV2eoO83bvKppGVl4Lm8IEscL0=";
};
sourceRoot = "${src.name}/libs/sdk-py";
build-system = [ poetry-core ];
build-system = [ hatchling ];
dependencies = [
httpx

View File

@ -5,13 +5,14 @@
fetchFromGitHub,
# build-system
poetry-core,
hatchling,
# dependencies
langchain-core,
langgraph-checkpoint,
langgraph-prebuilt,
langgraph-sdk,
pydantic,
xxhash,
# tests
@ -23,7 +24,6 @@
langgraph-checkpoint-sqlite,
langsmith,
psycopg,
pydantic,
pytest-asyncio,
pytest-mock,
pytest-repeat,
@ -38,30 +38,33 @@
}:
buildPythonPackage rec {
pname = "langgraph";
version = "0.4.1";
version = "0.6.1";
pyproject = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langgraph";
tag = version;
hash = "sha256-bTxtfduuuyRITZqhk15aWwxNwiZ7TMTgBOEPat6zVIc=";
hash = "sha256-8mubZSV1CDgYzykKaaWqn04yJldAgdGmgZDm54towWc=";
};
postgresqlTestSetupPost = ''
substituteInPlace tests/conftest.py \
substituteInPlace tests/conftest_store.py \
--replace-fail "DEFAULT_POSTGRES_URI = \"postgres://postgres:postgres@localhost:5442/\"" "DEFAULT_POSTGRES_URI = \"postgres:///$PGDATABASE\""
substituteInPlace tests/conftest_checkpointer.py \
--replace-fail "DEFAULT_POSTGRES_URI = \"postgres://postgres:postgres@localhost:5442/\"" "DEFAULT_POSTGRES_URI = \"postgres:///$PGDATABASE\""
'';
sourceRoot = "${src.name}/libs/langgraph";
build-system = [ poetry-core ];
build-system = [ hatchling ];
dependencies = [
langchain-core
langgraph-checkpoint
langgraph-prebuilt
langgraph-sdk
pydantic
xxhash
];
@ -96,10 +99,6 @@ buildPythonPackage rec {
];
disabledTests = [
# test is flaky due to pydantic error on the exception
"test_doesnt_warn_valid_schema"
"test_tool_node_inject_store"
# Disabling tests that requires to create new random databases
"test_cancel_graph_astream"
"test_cancel_graph_astream_events_v2"
@ -114,9 +113,9 @@ buildPythonPackage rec {
"test_pending_writes_resume"
"test_remove_message_via_state_update"
# pydantic.errors.PydanticForbiddenQualifier,
# see https://github.com/langchain-ai/langgraph/issues/4360
"test_state_schema_optional_values"
# Requires `langgraph dev` to be running
"test_remote_graph_basic_invoke"
"test_remote_graph_stream_messages_tuple"
];
disabledTestPaths = [

View File

@ -19,19 +19,19 @@
buildPythonPackage rec {
pname = "ormsgpack";
version = "1.9.1";
version = "1.10.0";
pyproject = true;
src = fetchFromGitHub {
owner = "aviramha";
repo = "ormsgpack";
tag = version;
hash = "sha256-lFKHXTYtYEjtu+nXemQnB0yjkFD69gr0n7XfJ1Hy3J0=";
hash = "sha256-7VESiHAkDynf31xrQQh0Vv5vSfMOjnVXRFackUQdB68=";
};
cargoDeps = rustPlatform.fetchCargoVendor {
inherit src;
hash = "sha256-jOEryJcE5+b0Y588fbDSyPcz5h4zYz2+40+lIfRDV1M=";
hash = "sha256-um6PzwL0M5lz4gDkTO/lvWJ0wwuCneNKRW8qysKMmM0=";
};
build-system = [