diff --git a/pkgs/development/python-modules/mlx-lm/default.nix b/pkgs/development/python-modules/mlx-lm/default.nix index cff7c736fa53..bad832123c92 100644 --- a/pkgs/development/python-modules/mlx-lm/default.nix +++ b/pkgs/development/python-modules/mlx-lm/default.nix @@ -24,14 +24,15 @@ buildPythonPackage (finalAttrs: { pname = "mlx-lm"; - version = "0.31.2"; + version = "0.31.3"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "ml-explore"; repo = "mlx-lm"; tag = "v${finalAttrs.version}"; - hash = "sha256-Ujt0KMs4dzIlbg7cg72TudAvlwJ4uWEG5Lx7+5j8cOU="; + hash = "sha256-DPOJfsIucG8mWt4ZKenymCJo/i9Jw+a+iuIygIIYkA8="; }; build-system = [ diff --git a/pkgs/development/python-modules/mlx/default.nix b/pkgs/development/python-modules/mlx/default.nix index 6cdc7cb6e6c9..9f22360363e3 100644 --- a/pkgs/development/python-modules/mlx/default.nix +++ b/pkgs/development/python-modules/mlx/default.nix @@ -20,6 +20,7 @@ # tests numpy, + psutil, pytestCheckHook, python, runCommand, @@ -41,14 +42,15 @@ let in buildPythonPackage (finalAttrs: { pname = "mlx"; - version = "0.31.1"; + version = "0.31.2"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "ml-explore"; repo = "mlx"; tag = "v${finalAttrs.version}"; - hash = "sha256-PiNk/MdMw9Vpat2KuslBTyaFuK+mJ4UvwJqBnysvvUU="; + hash = "sha256-0Oxacz61WGWZrpWw+fMQjEQfwOx1l1L2d0kWl54/LrQ="; }; patches = [ @@ -120,6 +122,7 @@ buildPythonPackage (finalAttrs: { # Run the mlx Python test suite. nativeCheckInputs = [ numpy + psutil pytestCheckHook ]; diff --git a/pkgs/development/python-modules/mlx/dont-fetch-json.patch b/pkgs/development/python-modules/mlx/dont-fetch-json.patch index e134d25d2cd3..c52f579922c1 100644 --- a/pkgs/development/python-modules/mlx/dont-fetch-json.patch +++ b/pkgs/development/python-modules/mlx/dont-fetch-json.patch @@ -1,8 +1,8 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index 2451aa65..f88d4889 100644 +index 6d24df02..113629ba 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -241,14 +241,6 @@ else() +@@ -313,14 +313,6 @@ else() set(MLX_BUILD_ACCELERATE OFF) endif() @@ -14,7 +14,6 @@ index 2451aa65..f88d4889 100644 -target_include_directories( - mlx PRIVATE $) - - add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/mlx) - - target_include_directories( - + # Add standalone JACCL library (RDMA over Thunderbolt distributed backend) + if(MLX_BUILD_CPU + AND ${CMAKE_SYSTEM_NAME} MATCHES "Darwin" diff --git a/pkgs/development/python-modules/mlx/dont-fetch-nanobind.patch b/pkgs/development/python-modules/mlx/dont-fetch-nanobind.patch index f2858448a93b..c9822ae1e2c7 100644 --- a/pkgs/development/python-modules/mlx/dont-fetch-nanobind.patch +++ b/pkgs/development/python-modules/mlx/dont-fetch-nanobind.patch @@ -1,15 +1,15 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index 0ed30932..e5842707 100644 +index a2395d02..6d24df02 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -339,13 +339,7 @@ if(MLX_BUILD_PYTHON_BINDINGS) +@@ -354,13 +354,7 @@ if(MLX_BUILD_PYTHON_BINDINGS) Python 3.10 COMPONENTS Interpreter Development.Module REQUIRED) - FetchContent_Declare( - nanobind - GIT_REPOSITORY https://github.com/wjakob/nanobind.git -- GIT_TAG v2.10.2 +- GIT_TAG v2.12.0 - GIT_SHALLOW TRUE - EXCLUDE_FROM_ALL) - FetchContent_MakeAvailable(nanobind)