From 038ab72940d4eac766e3fb1cb1e06ee9322c8a89 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Fri, 22 Jan 2021 09:33:10 +0100 Subject: [PATCH] python3Packages.cattrs: init at 1.1.2 --- .../python-modules/cattrs/default.nix | 35 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 37 insertions(+) create mode 100644 pkgs/development/python-modules/cattrs/default.nix diff --git a/pkgs/development/python-modules/cattrs/default.nix b/pkgs/development/python-modules/cattrs/default.nix new file mode 100644 index 000000000000..a48e29b827b7 --- /dev/null +++ b/pkgs/development/python-modules/cattrs/default.nix @@ -0,0 +1,35 @@ +{ lib +, attrs +, buildPythonPackage +, fetchFromGitHub +, hypothesis +, pytestCheckHook +}: + +buildPythonPackage rec { + pname = "cattrs"; + version = "1.1.2"; + + src = fetchFromGitHub { + owner = "Tinche"; + repo = pname; + rev = "v${version}"; + sha256 = "083d5mi6x7qcl26wlvwwn7gsp5chxlxkh4rp3a41w8cfwwr3h6l8"; + }; + + propagatedBuildInputs = [ attrs ]; + + checkInputs = [ + hypothesis + pytestCheckHook + ]; + + pythonImportsCheck = [ "cattr" ]; + + meta = with lib; { + description = "Python custom class converters for attrs"; + homepage = "https://github.com/Tinche/cattrs"; + license = with licenses; [ mit ]; + maintainers = with maintainers; [ fab ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 5744c8db921a..3edbe5de92d3 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -1161,6 +1161,8 @@ in { catboost = callPackage ../development/python-modules/catboost { }; + cattrs = callPackage ../development/python-modules/cattrs { }; + cbeams = callPackage ../misc/cbeams { }; cbor2 = callPackage ../development/python-modules/cbor2 { };