diff --git a/pkgs/development/python-modules/langgraph-cli/default.nix b/pkgs/development/python-modules/langgraph-cli/default.nix index faaab1ce7e80..f395d6b61d2c 100644 --- a/pkgs/development/python-modules/langgraph-cli/default.nix +++ b/pkgs/development/python-modules/langgraph-cli/default.nix @@ -8,7 +8,10 @@ # dependencies click, + langgraph, + langgraph-runtime-inmem, langgraph-sdk, + python-dotenv, # testing pytest-asyncio, @@ -40,21 +43,20 @@ buildPythonPackage rec { langgraph-sdk ]; - # Not yet. Depemnds on `langgraph-runtime-inmem` which isn't in github yet - # https://github.com/langchain-ai/langgraph/issues/5802 - # optional-dependencies = { - # "inmem" = [ - # langgraph-api - # langgraph-runtime-inmem - # python-dotenv - # ] - # } + optional-dependencies = { + "inmem" = [ + langgraph + langgraph-runtime-inmem + python-dotenv + ]; + }; nativeCheckInputs = [ pytest-asyncio pytestCheckHook docker-compose - ]; + ] + ++ lib.flatten (builtins.attrValues optional-dependencies); enabledTestPaths = [ "tests/unit_tests" ]; diff --git a/pkgs/development/python-modules/langgraph-runtime-inmem/default.nix b/pkgs/development/python-modules/langgraph-runtime-inmem/default.nix index 3dd52a5f6c7b..87d660138956 100644 --- a/pkgs/development/python-modules/langgraph-runtime-inmem/default.nix +++ b/pkgs/development/python-modules/langgraph-runtime-inmem/default.nix @@ -23,14 +23,6 @@ buildPythonPackage rec { hash = "sha256-chPmwJ+tUJoRK5xX9+r6mbYf95ZbX4Z3mP6Ra19nBxM="; }; - # 1.5.24 (now 1.5.25) only affects non-cpython builds - # upgrade: https://github.com/NixOS/nixpkgs/pull/431547 - postPatch = '' - substituteInPlace pyproject.toml \ - --replace "blockbuster>=1.5.24,<2.0.0" \ - "blockbuster>=1.5.23,<2.0.0" - ''; - build-system = [ hatchling ]; @@ -44,6 +36,12 @@ buildPythonPackage rec { structlog ]; + # Can remove after blockbuster version bump + # https://github.com/NixOS/nixpkgs/pull/431547 + pythonRelaxDeps = [ + "blockbuster" + ]; + pythonImportsCheck = [ "langgraph_runtime_inmem" ];