2021-01-15 22:18:51 +00:00
|
|
|
{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
|
2020-08-20 17:08:02 +00:00
|
|
|
, six, pytestCheckHook, pytest-benchmark, numpy, arrow, ruamel_yaml
|
2021-04-26 19:14:03 +00:00
|
|
|
, lz4, cloudpickle
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "construct";
|
2021-06-28 23:13:55 +00:00
|
|
|
version = "2.10.67";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-08-20 17:08:02 +00:00
|
|
|
disabled = pythonOlder "3.6";
|
|
|
|
|
|
|
|
# no tests in PyPI tarball
|
2020-04-24 23:36:52 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = pname;
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-06-28 23:13:55 +00:00
|
|
|
sha256 = "1nciwim745qk41l1ck4chx3vxpfr6cq4k3a4i7vfnnrd3s6szzsw";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-04-26 19:14:03 +00:00
|
|
|
# not an explicit dependency, but it's imported by an entrypoint
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
lz4
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [ pytestCheckHook pytest-benchmark numpy arrow ruamel_yaml cloudpickle ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
disabledTests = lib.optionals stdenv.isDarwin [ "test_multiprocessing" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-08-20 17:08:02 +00:00
|
|
|
pytestFlagsArray = [ "--benchmark-disable" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Powerful declarative parser (and builder) for binary data";
|
|
|
|
homepage = "https://construct.readthedocs.org/";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ bjornfor ];
|
|
|
|
};
|
|
|
|
}
|