2018-11-26 20:21:05 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, hopcroftkarp
|
|
|
|
, multiset
|
2019-06-08 15:23:27 +01:00
|
|
|
, pytest_3
|
2018-11-26 20:21:05 +00:00
|
|
|
, pytestrunner
|
|
|
|
, hypothesis
|
|
|
|
, setuptools_scm
|
2018-11-27 16:52:21 +00:00
|
|
|
, isPy27
|
2018-11-26 20:21:05 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "matchpy";
|
2019-06-08 15:23:27 +01:00
|
|
|
version = "0.5.1";
|
2018-11-27 16:52:21 +00:00
|
|
|
disabled = isPy27;
|
2018-11-26 20:21:05 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2019-06-08 15:23:27 +01:00
|
|
|
sha256 = "1vvf1cd9kw5z1mzvypc9f030nd18lgvvjc8j56b1s9b7dyslli2r";
|
2018-11-26 20:21:05 +00:00
|
|
|
};
|
|
|
|
|
2019-06-08 15:23:27 +01:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.cfg --replace "hypothesis>=3.6,<4.0" "hypothesis"
|
|
|
|
'';
|
|
|
|
|
2018-11-26 20:21:05 +00:00
|
|
|
buildInputs = [ setuptools_scm pytestrunner ];
|
2019-06-08 15:23:27 +01:00
|
|
|
checkInputs = [ pytest_3 hypothesis ];
|
2018-11-26 20:21:05 +00:00
|
|
|
propagatedBuildInputs = [ hopcroftkarp multiset ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A library for pattern matching on symbolic expressions";
|
|
|
|
homepage = https://github.com/HPAC/matchpy;
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = [ maintainers.costrouc ];
|
|
|
|
};
|
|
|
|
}
|