2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pythonOlder,
|
|
|
|
pybind11,
|
|
|
|
pytestCheckHook,
|
|
|
|
python-dateutil,
|
|
|
|
doxygen,
|
|
|
|
python,
|
|
|
|
pelican,
|
|
|
|
matplotlib,
|
2021-05-20 23:08:51 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pytomlpp";
|
2023-04-29 16:46:19 +00:00
|
|
|
version = "1.0.13";
|
2024-01-02 11:29:13 +00:00
|
|
|
format = "setuptools";
|
2021-05-20 23:08:51 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "bobfang1992";
|
|
|
|
repo = pname;
|
2021-12-06 16:07:01 +00:00
|
|
|
rev = "v${version}";
|
2021-05-20 23:08:51 +00:00
|
|
|
fetchSubmodules = true;
|
2023-04-29 16:46:19 +00:00
|
|
|
hash = "sha256-QJeXvj1M3Vq5ctmx7RhczONsPRXAecv3WhJgKWtNK+M=";
|
2021-05-20 23:08:51 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ pybind11 ];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-05-20 23:08:51 +00:00
|
|
|
pytestCheckHook
|
|
|
|
|
2021-07-04 02:40:35 +00:00
|
|
|
python-dateutil
|
2021-05-20 23:08:51 +00:00
|
|
|
doxygen
|
|
|
|
python
|
|
|
|
pelican
|
|
|
|
matplotlib
|
|
|
|
];
|
|
|
|
|
|
|
|
# pelican requires > 2.7
|
|
|
|
doCheck = !pythonOlder "3.6";
|
|
|
|
|
2022-04-15 01:41:22 +00:00
|
|
|
disabledTests = [
|
|
|
|
# incompatible with pytest7
|
|
|
|
# https://github.com/bobfang1992/pytomlpp/issues/66
|
|
|
|
"test_loads_valid_toml_files"
|
|
|
|
"test_round_trip_for_valid_toml_files"
|
|
|
|
"test_decode_encode_binary"
|
|
|
|
];
|
|
|
|
|
2021-05-20 23:08:51 +00:00
|
|
|
preCheck = ''
|
|
|
|
cd tests
|
|
|
|
'';
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "pytomlpp" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A python wrapper for tomlplusplus";
|
|
|
|
homepage = "https://github.com/bobfang1992/pytomlpp";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ evils ];
|
|
|
|
};
|
|
|
|
}
|