nixpkgs/pkgs/development/python-modules/dacite/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

47 lines
989 B
Nix
Raw Normal View History

2021-06-24 08:03:10 +00:00
{ lib
, fetchFromGitHub
, buildPythonPackage
, pythonOlder
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "dacite";
version = "1.8.0";
format = "setuptools";
2021-06-24 08:03:10 +00:00
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "konradhalas";
repo = pname;
rev = "refs/tags/v${version}";
hash = "sha256-aQwQHFWaXwTaA6GQgDcWT6ivE9YtWtHCTOtxDi503+M=";
2021-06-24 08:03:10 +00:00
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace "--benchmark-autosave --benchmark-json=benchmark.json" ""
'';
nativeCheckInputs = [
2021-06-24 08:03:10 +00:00
pytestCheckHook
];
pythonImportsCheck = [
"dacite"
];
2021-06-24 08:03:10 +00:00
disabledTestPaths = [
"tests/performance"
];
2021-06-24 08:03:10 +00:00
meta = with lib; {
description = "Python helper to create data classes from dictionaries";
homepage = "https://github.com/konradhalas/dacite";
changelog = "https://github.com/konradhalas/dacite/blob/v${version}/CHANGELOG.md";
2021-06-24 08:03:10 +00:00
license = licenses.mit;
maintainers = with maintainers; [ fab ];
};
}