about summary refs log tree commit diff
path: root/pkgs/development/python-modules/dask-yarn/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/python-modules/dask-yarn/default.nix')
-rw-r--r--pkgs/development/python-modules/dask-yarn/default.nix60
1 files changed, 35 insertions, 25 deletions
diff --git a/pkgs/development/python-modules/dask-yarn/default.nix b/pkgs/development/python-modules/dask-yarn/default.nix
index acea511b24952..8d60496d6a155 100644
--- a/pkgs/development/python-modules/dask-yarn/default.nix
+++ b/pkgs/development/python-modules/dask-yarn/default.nix
@@ -1,20 +1,23 @@
-{ lib
-, stdenv
-, buildPythonPackage
-, dask
-, distributed
-, fetchFromGitHub
-, fetchpatch
-, grpcio
-, pytestCheckHook
-, pythonOlder
-, skein
+{
+  lib,
+  buildPythonPackage,
+  pythonOlder,
+  fetchFromGitHub,
+  fetchpatch,
+  setuptools,
+  versioneer,
+  dask,
+  distributed,
+  grpcio,
+  skein,
+  pytestCheckHook,
+  stdenv,
 }:
 
 buildPythonPackage rec {
   pname = "dask-yarn";
   version = "0.9";
-  format = "setuptools";
+  pyproject = true;
 
   disabled = pythonOlder "3.7";
 
@@ -26,31 +29,37 @@ buildPythonPackage rec {
   };
 
   patches = [
-    (fetchpatch {  # https://github.com/dask/dask-yarn/pull/150
+    (fetchpatch {
+      # https://github.com/dask/dask-yarn/pull/150
       name = "address-deprecations-introduced-in-distributed-2021-07-0";
       url = "https://github.com/dask/dask-yarn/pull/150/commits/459848afcdc22568905ee98622c74e4071496423.patch";
       hash = "sha256-LS46QBdiAmsp4jQq4DdYdmmk1qzx5JZNTQUlRcRwY5k=";
     })
   ];
 
-  propagatedBuildInputs = [
-    distributed
+  postPatch = ''
+    rm versioneer.py
+  '';
+
+  build-system = [
+    setuptools
+    versioneer
+  ];
+
+  dependencies = [
     dask
+    distributed
     grpcio
     skein
   ];
 
-  nativeCheckInputs = [
-    pytestCheckHook
-  ];
+  nativeCheckInputs = [ pytestCheckHook ];
 
   preCheck = ''
     export HOME=$TMPDIR
   '';
 
-  pythonImportsCheck = [
-    "dask_yarn"
-  ];
+  pythonImportsCheck = [ "dask_yarn" ];
 
   disabledTests = [
     # skein.exceptions.DriverError: Failed to start java process
@@ -66,10 +75,11 @@ buildPythonPackage rec {
   meta = with lib; {
     description = "Deploy dask on YARN clusters";
     mainProgram = "dask-yarn";
-    longDescription = ''Dask-Yarn deploys Dask on YARN clusters,
-      such as are found in traditional Hadoop installations.
-      Dask-Yarn provides an easy interface to quickly start,
-      stop, and scale Dask clusters natively from Python.
+    longDescription = ''
+      Dask-Yarn deploys Dask on YARN clusters,
+            such as are found in traditional Hadoop installations.
+            Dask-Yarn provides an easy interface to quickly start,
+            stop, and scale Dask clusters natively from Python.
     '';
     homepage = "https://yarn.dask.org/";
     license = licenses.bsd3;