Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, msgpack 5, numpy 6, pandas 7, pydantic 8, pymongo 9, pytestCheckHook 10, pythonOlder 11, ruamel-yaml 12, tqdm 13}: 14 15buildPythonPackage rec { 16 pname = "monty"; 17 version = "2023.4.10"; 18 format = "setuptools"; 19 20 disabled = pythonOlder "3.7"; 21 22 src = fetchFromGitHub { 23 owner = "materialsvirtuallab"; 24 repo = pname; 25 rev = "refs/tags/v${version}"; 26 hash = "sha256-9of56ErJ03hU+KqxUjR4IiyU4XLJoothSwODlzSWv9Y="; 27 }; 28 29 postPatch = '' 30 substituteInPlace tests/test_os.py \ 31 --replace 'self.assertEqual("/usr/bin/find", which("/usr/bin/find"))' '#' 32 ''; 33 34 propagatedBuildInputs = [ 35 msgpack 36 ruamel-yaml 37 tqdm 38 ]; 39 40 nativeCheckInputs = [ 41 numpy 42 pandas 43 pydantic 44 pymongo 45 pytestCheckHook 46 ]; 47 48 pythonImportsCheck = [ 49 "monty" 50 ]; 51 52 disabledTests = [ 53 # Test file was removed and re-added after 2022.9.9 54 "test_reverse_readfile_gz" 55 "test_Path_objects" 56 "test_zopen" 57 "test_zpath" 58 ]; 59 60 meta = with lib; { 61 description = "Serves as a complement to the Python standard library by providing a suite of tools to solve many common problems"; 62 longDescription = " 63 Monty implements supplementary useful functions for Python that are not part of the 64 standard library. Examples include useful utilities like transparent support for zipped files, useful design 65 patterns such as singleton and cached_class, and many more. 66 "; 67 homepage = "https://github.com/materialsvirtuallab/monty"; 68 changelog = "https://github.com/materialsvirtuallab/monty/releases/tag/v${version}"; 69 license = licenses.mit; 70 maintainers = with maintainers; [ psyanticy ]; 71 }; 72}