diff --git a/pkgs/development/python-modules/langgraph-checkpoint-postgres/default.nix b/pkgs/development/python-modules/langgraph-checkpoint-postgres/default.nix index 9471af6c6c94..8a6b11d164e9 100644 --- a/pkgs/development/python-modules/langgraph-checkpoint-postgres/default.nix +++ b/pkgs/development/python-modules/langgraph-checkpoint-postgres/default.nix @@ -21,7 +21,7 @@ pytest-asyncio, # passthru - nix-update-script, + gitUpdater, }: buildPythonPackage rec { @@ -90,17 +90,14 @@ buildPythonPackage rec { pythonImportsCheck = [ "langgraph.checkpoint.postgres" ]; - passthru.updateScript = nix-update-script { - extraArgs = [ - "--version-regex" - "checkpointpostgres==(\\d+\\.\\d+\\.\\d+)" - ]; + passthru.updateScript = gitUpdater { + rev-prefix = "checkpointpostgres=="; }; meta = { description = "Library with a Postgres implementation of LangGraph checkpoint saver"; homepage = "https://github.com/langchain-ai/langgraph/tree/main/libs/checkpoint-postgres"; - changelog = "https://github.com/langchain-ai/langgraph/releases/tag/checkpointpostgres==${src.tag}"; + changelog = "https://github.com/langchain-ai/langgraph/releases/tag/${src.tag}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ drupol diff --git a/pkgs/development/python-modules/langgraph-checkpoint-sqlite/default.nix b/pkgs/development/python-modules/langgraph-checkpoint-sqlite/default.nix index 54efb25d7ca8..abe8da772df7 100644 --- a/pkgs/development/python-modules/langgraph-checkpoint-sqlite/default.nix +++ b/pkgs/development/python-modules/langgraph-checkpoint-sqlite/default.nix @@ -15,7 +15,7 @@ pytestCheckHook, # passthru - nix-update-script, + gitUpdater, }: buildPythonPackage rec { @@ -53,15 +53,12 @@ buildPythonPackage rec { pytestCheckHook ]; - passthru.updateScript = nix-update-script { - extraArgs = [ - "--version-regex" - "checkpoint-sqlite==(\\d+\\.\\d+\\.\\d+)" - ]; + passthru.updateScript = gitUpdater { + rev-prefix = "checkpointsqlite=="; }; meta = { - changelog = "https://github.com/langchain-ai/langgraph/releases/tag/checkpointsqlite==${version}"; + changelog = "https://github.com/langchain-ai/langgraph/releases/tag/${src.tag}"; description = "Library with a SQLite implementation of LangGraph checkpoint saver"; homepage = "https://github.com/langchain-ai/langgraph/tree/main/libs/checkpoint-sqlite"; license = lib.licenses.mit; diff --git a/pkgs/development/python-modules/langgraph-checkpoint/default.nix b/pkgs/development/python-modules/langgraph-checkpoint/default.nix index f2cfee22c69f..865d68a2b4b6 100644 --- a/pkgs/development/python-modules/langgraph-checkpoint/default.nix +++ b/pkgs/development/python-modules/langgraph-checkpoint/default.nix @@ -18,7 +18,7 @@ pytestCheckHook, # passthru - nix-update-script, + gitUpdater, }: buildPythonPackage rec { @@ -53,15 +53,12 @@ buildPythonPackage rec { pytestCheckHook ]; - passthru.updateScript = nix-update-script { - extraArgs = [ - "--version-regex" - "checkpoint==([0-9.]+)" - ]; + passthru.updateScript = gitUpdater { + rev-prefix = "checkpoint=="; }; meta = { - changelog = "https://github.com/langchain-ai/langgraph/releases/tag/checkpoint==${version}"; + changelog = "https://github.com/langchain-ai/langgraph/releases/tag/${src.tag}"; description = "Library with base interfaces for LangGraph checkpoint savers"; homepage = "https://github.com/langchain-ai/langgraph/tree/main/libs/checkpoint"; license = lib.licenses.mit; diff --git a/pkgs/development/python-modules/langgraph-cli/default.nix b/pkgs/development/python-modules/langgraph-cli/default.nix index 89d1bdcc2089..10b1f19c9454 100644 --- a/pkgs/development/python-modules/langgraph-cli/default.nix +++ b/pkgs/development/python-modules/langgraph-cli/default.nix @@ -15,7 +15,7 @@ docker-compose, # passthru - nix-update-script, + gitUpdater, }: buildPythonPackage rec { @@ -59,11 +59,8 @@ buildPythonPackage rec { "test_dockerfile_command_with_docker_compose" ]; - passthru.updateScript = nix-update-script { - extraArgs = [ - "--version-regex" - "cli==(\\d+\\.\\d+\\.\\d+)" - ]; + passthru.updateScript = gitUpdater { + rev-prefix = "cli=="; }; meta = { diff --git a/pkgs/development/python-modules/langgraph-prebuilt/default.nix b/pkgs/development/python-modules/langgraph-prebuilt/default.nix index 5e41724eebb7..96694f77fbff 100644 --- a/pkgs/development/python-modules/langgraph-prebuilt/default.nix +++ b/pkgs/development/python-modules/langgraph-prebuilt/default.nix @@ -24,7 +24,7 @@ xxhash, # passthru - nix-update-script, + gitUpdater, }: # langgraph-prebuilt isn't meant to be a standalone package but is bundled into langgraph at build time. # It exists so the langgraph team can iterate on it without having to rebuild langgraph. @@ -86,17 +86,14 @@ buildPythonPackage rec { "tests/test_react_agent.py" ]; - passthru.updateScript = nix-update-script { - extraArgs = [ - "--version-regex" - "prebuilt==(\\d+\\.\\d+\\.\\d+)" - ]; + passthru.updateScript = gitUpdater { + rev-prefix = "prebuilt=="; }; meta = { description = "Prebuilt agents add-on for Langgraph. Should always be bundled with langgraph"; homepage = "https://github.com/langchain-ai/langgraph/tree/main/libs/prebuilt"; - changelog = "https://github.com/langchain-ai/langgraph/releases/tag/${version}"; + changelog = "https://github.com/langchain-ai/langgraph/releases/tag/${src.tag}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ sarahec ]; }; diff --git a/pkgs/development/python-modules/langgraph-sdk/default.nix b/pkgs/development/python-modules/langgraph-sdk/default.nix index a1728f03f5d2..8dc6e7c23fc0 100644 --- a/pkgs/development/python-modules/langgraph-sdk/default.nix +++ b/pkgs/development/python-modules/langgraph-sdk/default.nix @@ -13,7 +13,7 @@ typing-extensions, # passthru - nix-update-script, + gitUpdater, }: buildPythonPackage rec { @@ -43,17 +43,14 @@ buildPythonPackage rec { pythonImportsCheck = [ "langgraph_sdk" ]; - passthru.updateScript = nix-update-script { - extraArgs = [ - "--version-regex" - "sdk==(\\d+\\.\\d+\\.\\d+)" - ]; + passthru.updateScript = gitUpdater { + rev-prefix = "sdk=="; }; meta = { description = "SDK for interacting with the LangGraph Cloud REST API"; homepage = "https://github.com/langchain-ai/langgraph/tree/main/libs/sdk-py"; - changelog = "https://github.com/langchain-ai/langgraph/releases/tag/sdk==${version}"; + changelog = "https://github.com/langchain-ai/langgraph/releases/tag/${src.tag}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ sarahec ]; }; diff --git a/pkgs/development/python-modules/langgraph/default.nix b/pkgs/development/python-modules/langgraph/default.nix index 3acda2264623..153206ad3c22 100644 --- a/pkgs/development/python-modules/langgraph/default.nix +++ b/pkgs/development/python-modules/langgraph/default.nix @@ -44,7 +44,7 @@ buildPythonPackage rec { src = fetchFromGitHub { owner = "langchain-ai"; repo = "langgraph"; - tag = "${version}"; + tag = version; hash = "sha256-bTxtfduuuyRITZqhk15aWwxNwiZ7TMTgBOEPat6zVIc="; }; @@ -128,17 +128,18 @@ buildPythonPackage rec { "tests/test_pregel_async.py" ]; + # Since `langgraph` is the only unprefixed package, we have to use an explicit match passthru.updateScript = nix-update-script { extraArgs = [ "--version-regex" - "^(\\d+\\.\\d+\\.\\d+)" + "([0-9.]+)" ]; }; meta = { description = "Build resilient language agents as graphs"; homepage = "https://github.com/langchain-ai/langgraph"; - changelog = "https://github.com/langchain-ai/langgraph/releases/tag/${version}"; + changelog = "https://github.com/langchain-ai/langgraph/releases/tag/${src.tag}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ sarahec ]; };