1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, pytestCheckHook
5, pythonOlder
6, setuptools
7, wheel
8}:
9
10buildPythonPackage rec {
11 pname = "objsize";
12 version = "0.7.0";
13 pyproject= true;
14
15 disabled = pythonOlder "3.7";
16
17 src = fetchFromGitHub {
18 owner = "liran-funaro";
19 repo = "objsize";
20 rev = "refs/tags/${version}";
21 hash = "sha256-wy4Tj+Q+4zymRdoN8Z7wcazJTb2lQ+XHY1Kta02R3R0=";
22 };
23
24 nativeBuildInputs = [
25 setuptools
26 wheel
27 ];
28
29 nativeCheckInputs = [
30 pytestCheckHook
31 ];
32
33 pythonImportsCheck = [
34 "objsize"
35 ];
36
37 pytestFlagsArray = [
38 "test_objsize.py"
39 ];
40
41 meta = with lib; {
42 description = "Traversal over objects subtree and calculate the total size";
43 homepage = "https://github.com/liran-funaro/objsize";
44 license = licenses.bsd3;
45 maintainers = with maintainers; [ ocfox ];
46 };
47}