git.iko.soy/typeable/nixpkgs
on master help sign in
pythonPackages.distributed: 1.15.1 -> 1.22.1

The github repository was downloaded instead of the pypi repository for testing (needed `conftest.py`). Major work was done on the underlying dependencies to make distributed work on python 2.7, 3+. Note that the test **do** take a significant amount of time (10-15 minutes). - moved to `python-modules` - compatible with 2.7, 3+ - all tests pass (previously tests were not run)

commit4f70170f8ab2b97f371f018e89e157219d22dcb6 authorChris Ostrouchov <chris.ostrouchov@gmail.com> dateWed 8 Aug 2018, 15:36 (8 years ago) parent7b92017
2 files changed+61−28
pkgs/development/python-modules/distributed/default.nix+59 pkgs/top-level/python-packages.nix+2−28
pkgs/development/python-modules/distributed/default.nixnew file+59
@@ -0,0 +1,59 @@
1+{ lib
2+, buildPythonPackage
3+, fetchFromGitHub
4+, pytest
5+, pytest-repeat
6+, pytest-faulthandler
7+, pytest-timeout
8+, mock
9+, joblib
10+, click
11+, cloudpickle
12+, dask
13+, msgpack
14+, psutil
15+, six
16+, sortedcontainers
17+, tblib
18+, toolz
19+, tornado
20+, zict
21+, pyyaml
22+, pythonOlder
23+, futures
24+, singledispatch
25+}:
26+
27+buildPythonPackage rec {
28+ pname = "distributed";
29+ version = "1.22.1";
30+
31+ # get full repository need conftest.py to run tests
32+ src = fetchFromGitHub {
33+ owner = "dask";
34+ repo = pname;
35+ rev = version;
36+ sha256 = "0xvx55rhbhlyys3kjndihwq6y6260qzy9mr3miclh5qddaiw2d5z";
37+ };
38+
39+ checkInputs = [ pytest pytest-repeat pytest-faulthandler pytest-timeout mock joblib ];
40+ propagatedBuildInputs = [
41+ click cloudpickle dask msgpack psutil six
42+ sortedcontainers tblib toolz tornado zict pyyaml
43+ ] ++ lib.optional (pythonOlder "3.2") [ futures ]
44+ ++ lib.optional (pythonOlder "3.4") [ singledispatch ];
45+
46+ # tests take about 10-15 minutes
47+ # ignore 5 cli tests out of 1000 total tests that fail due to subprocesses
48+ # these tests are not critical to the library (only the cli)
49+ checkPhase = ''
50+ py.test distributed -m "not avoid-travis" -r s --timeout-method=thread --timeout=0 --durations=20 --ignore="distributed/cli/tests"
51+ '';
52+
53+ meta = {
54+ description = "Distributed computation in Python.";
55+ homepage = http://distributed.readthedocs.io/en/latest/;
56+ license = lib.licenses.bsd3;
57+ maintainers = with lib.maintainers; [ teh costrouc ];
58+ };
59+}
pkgs/top-level/python-packages.nix+2−28
@@ -272,6 +272,8 @@ in {
272272
273273 distorm3 = callPackage ../development/python-modules/distorm3 { };
274274
275+ distributed = callPackage ../development/python-modules/distributed { };
276+
275277 dogtail = callPackage ../development/python-modules/dogtail { };
276278
277279 diff-match-patch = callPackage ../development/python-modules/diff-match-patch { };
@@ -1982,34 +1984,6 @@ in {
19821984
19831985 zict = callPackage ../development/python-modules/zict { };
19841986
1985− distributed = buildPythonPackage rec {
1986−
1987− name = "distributed-${version}";
1988− version = "1.15.1";
1989−
1990− src = pkgs.fetchurl {
1991− url = "mirror://pypi/d/distributed/${name}.tar.gz";
1992− sha256 = "037a07sdf2ch1d360nqwqz3b4ld8msydng7mw4i5s902v7xr05l6";
1993− };
1994−
1995− buildInputs = with self; [ pytest docutils ];
1996− propagatedBuildInputs = with self; [
1997− dask six boto3 s3fs tblib locket msgpack-python click cloudpickle tornado
1998− psutil botocore zict lz4 sortedcollections sortedcontainers
1999− ] ++ (if !isPy3k then [ singledispatch ] else []);
2000−
2001− # py.test not picking up local config file, even when running
2002− # manually: E ValueError: no option named '--runslow'
2003− doCheck = false;
2004−
2005− meta = {
2006− description = "Distributed computation in Python.";
2007− homepage = "http://distributed.readthedocs.io/en/latest/";
2008− license = licenses.bsd3;
2009− maintainers = with maintainers; [ teh ];
2010− };
2011− };
2012−
20131987 digital-ocean = callPackage ../development/python-modules/digitalocean { };
20141988
20151989 leather = callPackage ../development/python-modules/leather { };