depot/third_party/nixpkgs/pkgs/development/python-modules/strct/default.nix
Default email 5c370c0b2a Project import generated by Copybara.
GitOrigin-RevId: 33d1e753c82ffc557b4a585c77de43d4c922ebb5
2024-05-15 17:35:15 +02:00

55 lines
1 KiB
Nix

{ lib
, fetchFromGitHub
, buildPythonPackage
, setuptools
, pytestCheckHook
, sortedcontainers
}:
buildPythonPackage rec {
pname = "strct";
version = "0.0.34";
pyproject = true;
src = fetchFromGitHub {
owner = "shaypal5";
repo = "strct";
rev = "v${version}";
hash = "sha256-uPM2U+emZUCGqEhIeTBmaOu8eSfK4arqvv9bItBWpUs=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace-fail \
'"--cov' \
'#"--cov'
'';
# don't append .dev0 to version
env.RELEASING_PROCESS = "1";
nativeBuildInputs = [
setuptools
];
nativeCheckInputs = [
pytestCheckHook
sortedcontainers
];
pythonImportsCheck = [
"strct"
"strct.dicts"
"strct.hash"
"strct.lists"
"strct.sets"
"strct.sortedlists"
];
meta = with lib; {
description = "A small pure-python package for data structure related utility functions";
homepage = "https://github.com/shaypal5/strct";
license = licenses.mit;
maintainers = with maintainers; [ pbsds ];
};
}