1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, pytestCheckHook 5, pythonOlder 6, setuptools-scm 7}: 8 9buildPythonPackage rec { 10 pname = "dictdiffer"; 11 version = "0.9.0"; 12 format = "setuptools"; 13 14 disabled = pythonOlder "3.7"; 15 16 src = fetchFromGitHub { 17 owner = "inveniosoftware"; 18 repo = pname; 19 rev = "v${version}"; 20 hash = "sha256-lQyPs3lQWtsvNPuvvwJUTDzrFaOX5uwGuRHe3yWUheU="; 21 }; 22 23 SETUPTOOLS_SCM_PRETEND_VERSION = version; 24 25 nativeBuildInputs = [ 26 setuptools-scm 27 ]; 28 29 nativeCheckInputs = [ 30 pytestCheckHook 31 ]; 32 33 postPatch = '' 34 substituteInPlace setup.py \ 35 --replace "'pytest-runner>=2.7'," "" 36 substituteInPlace pytest.ini \ 37 --replace ' --isort --pydocstyle --pycodestyle --doctest-glob="*.rst" --doctest-modules --cov=dictdiffer --cov-report=term-missing' "" 38 ''; 39 40 pythonImportsCheck = [ 41 "dictdiffer" 42 ]; 43 44 meta = with lib; { 45 description = "Module to diff and patch dictionaries"; 46 homepage = "https://github.com/inveniosoftware/dictdiffer"; 47 license = licenses.mit; 48 maintainers = with maintainers; [ fab ]; 49 }; 50}