2019-02-24 19:14:28 +00:00
|
|
|
{ lib
|
2018-10-17 04:24:31 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2020-04-03 16:20:41 +00:00
|
|
|
, pythonOlder
|
|
|
|
, setuptools_scm
|
2020-08-29 11:55:49 +00:00
|
|
|
, importlib-metadata
|
|
|
|
, packaging
|
2020-04-03 16:20:41 +00:00
|
|
|
# Check Inputs
|
|
|
|
, pytestCheckHook
|
|
|
|
, numpy
|
|
|
|
, matplotlib
|
|
|
|
, uncertainties
|
2018-10-17 04:24:31 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pint";
|
2020-07-06 10:34:54 +00:00
|
|
|
version = "0.14";
|
2018-10-17 04:24:31 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
2019-02-24 19:14:28 +00:00
|
|
|
inherit version;
|
|
|
|
pname = "Pint";
|
2020-07-06 10:34:54 +00:00
|
|
|
sha256 = "0wkzb7g20wzpqr3xaqpq96dlfv6irw202icsz81ys8npp7mm194s";
|
2018-10-17 04:24:31 +00:00
|
|
|
};
|
|
|
|
|
2020-04-03 16:20:41 +00:00
|
|
|
disabled = pythonOlder "3.6";
|
|
|
|
|
2020-08-29 11:55:49 +00:00
|
|
|
nativeBuildInputs = [ setuptools_scm ];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ packaging ]
|
|
|
|
++ lib.optionals (pythonOlder "3.8") [ importlib-metadata ];
|
2020-04-03 16:20:41 +00:00
|
|
|
|
|
|
|
# Test suite explicitly requires pytest
|
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
numpy
|
|
|
|
matplotlib
|
|
|
|
uncertainties
|
|
|
|
];
|
|
|
|
dontUseSetuptoolsCheck = true;
|
2019-02-24 19:14:28 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
2018-10-17 04:24:31 +00:00
|
|
|
description = "Physical quantities module";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
homepage = "https://github.com/hgrecco/pint/";
|
2019-02-24 19:14:28 +00:00
|
|
|
maintainers = [ maintainers.costrouc ];
|
2018-10-17 04:24:31 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|