1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, pytestCheckHook
5}:
6
7let
8 sortedcontainers = buildPythonPackage rec {
9 pname = "sortedcontainers";
10 version = "2.4.0";
11
12 src = fetchFromGitHub {
13 owner = "grantjenks";
14 repo = "python-sortedcontainers";
15 rev = "v${version}";
16 hash = "sha256-YRbSM2isWi7AzfquFvuZBlpEMNUnBJTBLBn0/XYVHKQ=";
17 };
18
19 doCheck = false;
20
21 nativeCheckInputs = [
22 pytestCheckHook
23 ];
24
25 pythonImportsCheck = [ "sortedcontainers" ];
26
27 passthru.tests = {
28 pytest = sortedcontainers.overridePythonAttrs (_: { doCheck = true; });
29 };
30
31 meta = with lib; {
32 description = "Python Sorted Container Types: SortedList, SortedDict, and SortedSet";
33 homepage = "https://grantjenks.com/docs/sortedcontainers/";
34 license = licenses.asl20;
35 maintainers = with maintainers; [ ];
36 };
37 };
38in
39sortedcontainers