depot/third_party/nixpkgs/pkgs/development/python-modules/dataclasses-json/default.nix

49 lines
942 B
Nix
Raw Normal View History

{ lib
, buildPythonPackage
, fetchFromGitHub
, stringcase
, typing-inspect
, marshmallow-enum
, hypothesis
, mypy
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "dataclasses-json";
version = "0.5.4";
src = fetchFromGitHub {
owner = "lidatong";
repo = pname;
rev = "v${version}";
sha256 = "193xklf1xrsin7fr24yqx5ckr4m5s9v1bdyr00qr51j74hiy8qsv";
};
propagatedBuildInputs = [
stringcase
typing-inspect
marshmallow-enum
];
checkInputs = [
hypothesis
mypy
pytestCheckHook
];
disabledTests = [
# AssertionError: Type annotations check failed
"test_type_hints"
];
pythonImportsCheck = [ "dataclasses_json" ];
meta = with lib; {
description = "Simple API for encoding and decoding dataclasses to and from JSON";
homepage = "https://github.com/lidatong/dataclasses-json";
license = licenses.mit;
maintainers = with maintainers; [ albakham ];
};
}