anki-bin: 24.06.3 -> 24.11 (#360722)
[NixPkgs.git] / pkgs / development / python-modules / ubelt / default.nix
blob11491426bd0975826620c4dbfc6199db72110d87
2   lib,
3   stdenv,
4   buildPythonPackage,
5   fetchFromGitHub,
6   pythonOlder,
7   setuptools,
8   wheel,
9   numpy,
10   python-dateutil,
11   xxhash,
12   pytestCheckHook,
13   requests,
14   xdoctest,
17 buildPythonPackage rec {
18   pname = "ubelt";
19   version = "1.3.6";
20   pyproject = true;
22   disabled = pythonOlder "3.6";
24   src = fetchFromGitHub {
25     owner = "Erotemic";
26     repo = "ubelt";
27     rev = "refs/tags/v${version}";
28     hash = "sha256-ygoJqyTscfuZVDGVbrZobZFvlcuF4HavTU65tmhyU+w=";
29   };
31   nativeBuildInputs = [
32     setuptools
33     wheel
34   ];
36   optional-dependencies = {
37     optional = [
38       numpy
39       python-dateutil
40       xxhash
41     ];
42   };
44   nativeCheckInputs = [
45     pytestCheckHook
46     requests
47     xdoctest
48   ];
50   preCheck = ''
51     export HOME=$TMPDIR
52   '';
54   disabledTests = lib.optionals stdenv.hostPlatform.isDarwin [
55     # fail due to sandbox environment
56     "CacheStamp.expired"
57     "userhome"
58   ];
60   pythonImportsCheck = [ "ubelt" ];
62   __darwinAllowLocalNetworking = true;
64   meta = with lib; {
65     description = "Python utility library with a stdlib like feel and extra batteries. Paths, Progress, Dicts, Downloads, Caching, Hashing: ubelt makes it easy";
66     homepage = "https://github.com/Erotemic/ubelt";
67     changelog = "https://github.com/Erotemic/ubelt/blob/${src.rev}/CHANGELOG.md";
68     license = licenses.asl20;
69     maintainers = with maintainers; [ natsukium ];
70   };