1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 pythonOlder, 6 poetry-core, 7 textfsm, 8 invoke, 9 pytestCheckHook, 10 ruamel-yaml, 11 toml, 12 yamllint, 13}: 14 15buildPythonPackage rec { 16 pname = "ntc-templates"; 17 version = "4.4.0"; 18 format = "pyproject"; 19 20 disabled = pythonOlder "3.7"; 21 22 src = fetchFromGitHub { 23 owner = "networktocode"; 24 repo = pname; 25 rev = "refs/tags/v${version}"; 26 hash = "sha256-8Lzh6ku2TUQFatqbOb5JIc/WkRPegx/gNnT53DErMuk="; 27 }; 28 29 nativeBuildInputs = [ poetry-core ]; 30 31 propagatedBuildInputs = [ textfsm ]; 32 33 nativeCheckInputs = [ 34 invoke 35 pytestCheckHook 36 ruamel-yaml 37 toml 38 yamllint 39 ]; 40 41 # https://github.com/networktocode/ntc-templates/issues/743 42 disabledTests = [ 43 "test_raw_data_against_mock" 44 "test_verify_parsed_and_reference_data_exists" 45 ]; 46 47 meta = with lib; { 48 description = "TextFSM templates for parsing show commands of network devices"; 49 homepage = "https://github.com/networktocode/ntc-templates"; 50 changelog = "https://github.com/networktocode/ntc-templates/releases/tag/v${version}"; 51 license = licenses.asl20; 52 maintainers = with maintainers; [ ]; 53 }; 54}