Merge pull request #115360 from SuperSandro2000/datashader

This commit is contained in:
Sandro 2021-03-08 01:37:04 +01:00 committed by GitHub
commit 39acd7f220
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 48 additions and 57 deletions

View file

@ -12,12 +12,14 @@
, dill
, pandas
, partd
, pytest-xdist
, withExtraComplete ? false
, distributed
}:
buildPythonPackage rec {
pname = "dask";
version = "2021.03.0";
disabled = pythonOlder "3.5";
src = fetchFromGitHub {
@ -27,13 +29,6 @@ buildPythonPackage rec {
sha256 = "LACv7lWpQULQknNGX/9vH9ckLsypbqKDGnsNBgKT1eI=";
};
checkInputs = [
pytestCheckHook
pytest-rerunfailures
];
dontUseSetuptoolsCheck = true;
propagatedBuildInputs = [
bokeh
cloudpickle
@ -43,8 +38,20 @@ buildPythonPackage rec {
pandas
partd
toolz
] ++ lib.optionals withExtraComplete [
distributed
];
doCheck = false;
checkInputs = [
pytestCheckHook
pytest-rerunfailures
pytest-xdist
];
dontUseSetuptoolsCheck = true;
postPatch = ''
# versioneer hack to set version of github package
echo "def get_versions(): return {'dirty': False, 'error': None, 'full-revisionid': None, 'version': '${version}'}" > dask/_version.py
@ -54,21 +61,18 @@ buildPythonPackage rec {
--replace "cmdclass=versioneer.get_cmdclass()," ""
'';
#pytestFlagsArray = [ "-n $NIX_BUILD_CORES" ];
pytestFlagsArray = [ "-n $NIX_BUILD_CORES" ];
disabledTests = [
"test_argwhere_str"
"test_count_nonzero_str"
"rolling_methods" # floating percision error ~0.1*10^8 small
"num_workers_config" # flaky
"test_2args_with_array[pandas1-darray1-ldexp]" # flaky
"test_annotation_pack_unpack"
"test_annotations_blockwise_unpack"
];
meta = {
meta = with lib; {
description = "Minimal task scheduling abstraction";
homepage = "https://dask.org/";
changelog = "https://docs.dask.org/en/latest/changelog.html";
license = lib.licenses.bsd3;
maintainers = with lib.maintainers; [ fridh ];
license = licenses.bsd3;
maintainers = with maintainers; [ fridh ];
};
}

View file

@ -1,9 +1,7 @@
{ lib
, buildPythonPackage
, fetchPypi
, fetchpatch
, dask
, distributed
, bokeh
, toolz
, datashape
@ -15,38 +13,26 @@
, colorcet
, param
, pyct
, pyyaml
, requests
, scikitimage
, scipy
, pytest
, pytest-benchmark
, flake8
, pytestCheckHook
, nbsmoke
, fastparquet
, testpath
, nbconvert
, pytest_xdist
, pytest-xdist
, netcdf4
}:
buildPythonPackage rec {
pname = "datashader";
version = "0.11.1";
version = "0.12.0";
src = fetchPypi {
inherit pname version;
sha256 = "b1f80415f72f92ccb660aaea7b2881ddd35d07254f7c44101709d42e819d6be6";
sha256 = "sha256-CnV6ne3cbMtoVUBDqXf4n3tlEMzuKp7H8Ju7Qrzn9es=";
};
patches = [ (fetchpatch {
# Unpins pyct==0.46 (Sep. 11, 2020).
# Will be incorporated into the next datashader release after 0.11.1
url = "https://github.com/holoviz/datashader/pull/960/commits/d7a462fa399106c34fd0d44505a8a73789dbf874.patch";
sha256 = "1wqsk9dpxnkxr49fa7y5q6ahin80cvys05lnirs2w2p1dja35y4x";
})];
propagatedBuildInputs = [
dask
distributed
bokeh
toolz
datashape
@ -58,30 +44,29 @@ buildPythonPackage rec {
colorcet
param
pyct
pyyaml
requests
scikitimage
scipy
testpath
];
checkInputs = [
pytest
pytest-benchmark
pytest_xdist # not needed
flake8
pytestCheckHook
pytest-xdist # not needed
nbsmoke
fastparquet
pandas
nbconvert
netcdf4
];
# dask doesn't do well with large core counts
checkPhase = ''
pytest -n $NIX_BUILD_CORES datashader -k 'not dask.array and not test_simple_nested'
'';
pytestFlagsArray = [
"-n $NIX_BUILD_CORES"
"datashader"
];
meta = with lib; {
disabledTestPaths = [
# 31/50 tests fail with TypeErrors
"datashader/tests/test_datatypes.py"
];
meta = with lib;{
description = "Data visualization toolchain based on aggregating into a grid";
homepage = "https://datashader.org";
license = licenses.bsd3;

View file

@ -20,13 +20,13 @@
buildPythonPackage rec {
pname = "distributed";
version = "2.30.1";
version = "2021.3.0";
disabled = pythonOlder "3.6";
# get full repository need conftest.py to run tests
src = fetchPypi {
inherit pname version;
sha256 = "1421d3b84a0885aeb2c4bdc9e8896729c0f053a9375596c9de8864e055e2ac8e";
sha256 = "sha256-Qn/n4Ee7rXQTxl1X5W+k1rHPkh/SBqPSyquUv5FTw9s=";
};
propagatedBuildInputs = [
@ -38,11 +38,11 @@ buildPythonPackage rec {
doCheck = false;
pythonImportsCheck = [ "distributed" ];
meta = {
meta = with lib; {
description = "Distributed computation in Python.";
homepage = "https://distributed.readthedocs.io/en/latest/";
license = lib.licenses.bsd3;
platforms = lib.platforms.x86; # fails on aarch64
maintainers = with lib.maintainers; [ teh costrouc ];
license = licenses.bsd3;
platforms = platforms.x86; # fails on aarch64
maintainers = with maintainers; [ teh costrouc ];
};
}

View file

@ -1660,7 +1660,9 @@ in {
datasette = callPackage ../development/python-modules/datasette { };
datashader = callPackage ../development/python-modules/datashader { };
datashader = callPackage ../development/python-modules/datashader {
dask = self.dask.override { withExtraComplete = true; };
};
datashape = callPackage ../development/python-modules/datashape { };