2021-02-16 17:04:54 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
2021-08-23 08:02:39 +00:00
|
|
|
, fetchFromGitHub
|
2021-02-16 17:04:54 +00:00
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
2021-08-23 08:02:39 +00:00
|
|
|
, mypy
|
|
|
|
, typing-extensions
|
2021-02-16 17:04:54 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "immutables";
|
2022-09-22 12:36:57 +00:00
|
|
|
version = "0.19";
|
2022-06-26 10:26:21 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
2021-08-23 08:02:39 +00:00
|
|
|
disabled = pythonOlder "3.6";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-08-23 08:02:39 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "MagicStack";
|
|
|
|
repo = pname;
|
2022-09-22 12:36:57 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
hash = "sha256-yW+pmAryBp6bvjolN91ACDkk5zxvKfu4nRLQSy71kqs=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2022-06-26 10:26:21 +00:00
|
|
|
propagatedBuildInputs = lib.optionals (pythonOlder "3.8") [
|
2021-08-23 08:02:39 +00:00
|
|
|
typing-extensions
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-08-23 08:02:39 +00:00
|
|
|
mypy
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# Version mismatch
|
|
|
|
"testMypyImmu"
|
|
|
|
];
|
2021-02-16 17:04:54 +00:00
|
|
|
|
2022-06-26 10:26:21 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"immutables"
|
|
|
|
];
|
2021-02-16 17:04:54 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
2022-06-26 10:26:21 +00:00
|
|
|
description = "An immutable mapping type";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/MagicStack/immutables";
|
2021-02-16 17:04:54 +00:00
|
|
|
license = with licenses; [ asl20 ];
|
|
|
|
maintainers = with maintainers; [ catern ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|